@activepieces/piece-bigcommerce 0.1.10 → 0.1.11
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 +4 -4
package/package.json
CHANGED
package/src/index.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
"use strict";var bu=Object.create;var Xe=Object.defineProperty;var Tu=Object.getOwnPropertyDescriptor;var Iu=Object.getOwnPropertyNames;var Eu=Object.getPrototypeOf,Su=Object.prototype.hasOwnProperty;var o=(e,t)=>Xe(e,"name",{value:t,configurable:!0});var $=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),An=(e,t)=>{for(var r in t)Xe(e,r,{get:t[r],enumerable:!0})},zn=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of Iu(t))!Su.call(e,i)&&i!==r&&Xe(e,i,{get:()=>t[i],enumerable:!(n=Tu(t,i))||n.enumerable});return e};var Ce=(e,t,r)=>(r=e!=null?bu(Eu(e)):{},zn(t||!e||!e.__esModule?Xe(r,"default",{value:e,enumerable:!0}):r,e)),$u=e=>zn(Xe({},"__esModule",{value:!0}),e);var Wo=$((qo,Ft)=>{(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"),i=new RegExp("^0x[a-f0-9]+$","i"),u="%[0-9a-z]{1,}",c="(?:[0-9a-f]+::?)+",l={zoneIndex:new RegExp(u,"i"),native:new RegExp(`^(::)?(${c})?([0-9a-f]+)?(::)?(${u})?$`,"i"),deprecatedTransitional:new RegExp(`^(?:::)(${t}\\.${t}\\.${t}\\.${t}(${u})?)$`,"i"),transitional:new RegExp(`^((?:${c})|(?:::)(?:${c})?)${t}\\.${t}\\.${t}\\.${t}(${u})?$`,"i")};function y(s,d){if(s.indexOf("::")!==s.lastIndexOf("::"))return null;let g=0,m=-1,x=(s.match(l.zoneIndex)||[])[0],b,F;for(x&&(x=x.substring(1),s=s.replace(/%.+$/,""));(m=s.indexOf(":",m+1))>=0;)g++;if(s.substr(0,2)==="::"&&g--,s.substr(-2,2)==="::"&&g--,g>d)return null;for(F=d-g,b=":";F--;)b+="0:";return s=s.replace("::",b),s[0]===":"&&(s=s.slice(1)),s[s.length-1]===":"&&(s=s.slice(0,-1)),d=function(){let ie=s.split(":"),ce=[];for(let Je=0;Je<ie.length;Je++)ce.push(parseInt(ie[Je],16));return ce}(),{parts:d,zoneId:x}}o(y,"expandIPv6");function v(s,d,g,m){if(s.length!==d.length)throw new Error("ipaddr: cannot match CIDR for objects with different lengths");let x=0,b;for(;m>0;){if(b=g-m,b<0&&(b=0),s[x]>>b!==d[x]>>b)return!1;m-=g,x+=1}return!0}o(v,"matchCIDR");function P(s){if(i.test(s))return parseInt(s,16);if(s[0]==="0"&&!isNaN(parseInt(s[1],10))){if(n.test(s))return parseInt(s,8);throw new Error(`ipaddr: cannot parse ${s} as octal`)}return parseInt(s,10)}o(P,"parseIntAuto");function A(s,d){for(;s.length<d;)s=`0${s}`;return s}o(A,"padPart");let _={};_.IPv4=function(){function s(d){if(d.length!==4)throw new Error("ipaddr: ipv4 octet count should be 4");let g,m;for(g=0;g<d.length;g++)if(m=d[g],!(0<=m&&m<=255))throw new Error("ipaddr: ipv4 octet should fit in 8 bits");this.octets=d}return o(s,"IPv4"),s.prototype.SpecialRanges={unspecified:[[new s([0,0,0,0]),8]],broadcast:[[new s([255,255,255,255]),32]],multicast:[[new s([224,0,0,0]),4]],linkLocal:[[new s([169,254,0,0]),16]],loopback:[[new s([127,0,0,0]),8]],carrierGradeNat:[[new s([100,64,0,0]),10]],private:[[new s([10,0,0,0]),8],[new s([172,16,0,0]),12],[new s([192,168,0,0]),16]],reserved:[[new s([192,0,0,0]),24],[new s([192,0,2,0]),24],[new s([192,88,99,0]),24],[new s([198,18,0,0]),15],[new s([198,51,100,0]),24],[new s([203,0,113,0]),24],[new s([240,0,0,0]),4]],as112:[[new s([192,175,48,0]),24],[new s([192,31,196,0]),24]],amt:[[new s([192,52,193,0]),24]]},s.prototype.kind=function(){return"ipv4"},s.prototype.match=function(d,g){let m;if(g===void 0&&(m=d,d=m[0],g=m[1]),d.kind()!=="ipv4")throw new Error("ipaddr: cannot match ipv4 address with non-ipv4 one");return v(this.octets,d.octets,8,g)},s.prototype.prefixLengthFromSubnetMask=function(){let d=0,g=!1,m={0:8,128:7,192:6,224:5,240:4,248:3,252:2,254:1,255:0},x,b,F;for(x=3;x>=0;x-=1)if(b=this.octets[x],b in m){if(F=m[b],g&&F!==0)return null;F!==8&&(g=!0),d+=F}else return null;return 32-d},s.prototype.range=function(){return _.subnetMatch(this,this.SpecialRanges)},s.prototype.toByteArray=function(){return this.octets.slice(0)},s.prototype.toIPv4MappedAddress=function(){return _.IPv6.parse(`::ffff:${this.toString()}`)},s.prototype.toNormalizedString=function(){return this.toString()},s.prototype.toString=function(){return this.octets.join(".")},s}(),_.IPv4.broadcastAddressFromCIDR=function(s){try{let d=this.parseCIDR(s),g=d[0].toByteArray(),m=this.subnetMaskFromPrefixLength(d[1]).toByteArray(),x=[],b=0;for(;b<4;)x.push(parseInt(g[b],10)|parseInt(m[b],10)^255),b++;return new this(x)}catch{throw new Error("ipaddr: the address does not have IPv4 CIDR format")}},_.IPv4.isIPv4=function(s){return this.parser(s)!==null},_.IPv4.isValid=function(s){try{return new this(this.parser(s)),!0}catch{return!1}},_.IPv4.isValidCIDR=function(s){try{return this.parseCIDR(s),!0}catch{return!1}},_.IPv4.isValidFourPartDecimal=function(s){return!!(_.IPv4.isValid(s)&&s.match(/^(0|[1-9]\d*)(\.(0|[1-9]\d*)){3}$/))},_.IPv4.isValidCIDRFourPartDecimal=function(s){let d=s.match(/^(.+)\/(\d+)$/);return!_.IPv4.isValidCIDR(s)||!d?!1:_.IPv4.isValidFourPartDecimal(d[1])},_.IPv4.networkAddressFromCIDR=function(s){let d,g,m,x,b;try{for(d=this.parseCIDR(s),m=d[0].toByteArray(),b=this.subnetMaskFromPrefixLength(d[1]).toByteArray(),x=[],g=0;g<4;)x.push(parseInt(m[g],10)&parseInt(b[g],10)),g++;return new this(x)}catch{throw new Error("ipaddr: the address does not have IPv4 CIDR format")}},_.IPv4.parse=function(s){let d=this.parser(s);if(d===null)throw new Error("ipaddr: string is not formatted like an IPv4 Address");return new this(d)},_.IPv4.parseCIDR=function(s){let d;if(d=s.match(/^(.+)\/(\d+)$/)){let g=parseInt(d[2]);if(g>=0&&g<=32){let m=[this.parse(d[1]),g];return Object.defineProperty(m,"toString",{value:o(function(){return this.join("/")},"value")}),m}}throw new Error("ipaddr: string is not formatted like an IPv4 CIDR range")},_.IPv4.parser=function(s){let d,g,m;if(d=s.match(r.fourOctet))return function(){let x=d.slice(1,6),b=[];for(let F=0;F<x.length;F++)g=x[F],b.push(P(g));return b}();if(d=s.match(r.longValue)){if(m=P(d[1]),m>4294967295||m<0)throw new Error("ipaddr: address outside defined range");return function(){let x=[],b;for(b=0;b<=24;b+=8)x.push(m>>b&255);return x}().reverse()}else return(d=s.match(r.twoOctet))?function(){let x=d.slice(1,4),b=[];if(m=P(x[1]),m>16777215||m<0)throw new Error("ipaddr: address outside defined range");return b.push(P(x[0])),b.push(m>>16&255),b.push(m>>8&255),b.push(m&255),b}():(d=s.match(r.threeOctet))?function(){let x=d.slice(1,5),b=[];if(m=P(x[2]),m>65535||m<0)throw new Error("ipaddr: address outside defined range");return b.push(P(x[0])),b.push(P(x[1])),b.push(m>>8&255),b.push(m&255),b}():null},_.IPv4.subnetMaskFromPrefixLength=function(s){if(s=parseInt(s),s<0||s>32)throw new Error("ipaddr: invalid IPv4 prefix length");let d=[0,0,0,0],g=0,m=Math.floor(s/8);for(;g<m;)d[g]=255,g++;return m<4&&(d[m]=Math.pow(2,s%8)-1<<8-s%8),new this(d)},_.IPv6=function(){function s(d,g){let m,x;if(d.length===16)for(this.parts=[],m=0;m<=14;m+=2)this.parts.push(d[m]<<8|d[m+1]);else if(d.length===8)this.parts=d;else throw new Error("ipaddr: ipv6 part count should be 8 or 16");for(m=0;m<this.parts.length;m++)if(x=this.parts[m],!(0<=x&&x<=65535))throw new Error("ipaddr: ipv6 part should fit in 16 bits");g&&(this.zoneId=g)}return o(s,"IPv6"),s.prototype.SpecialRanges={unspecified:[new s([0,0,0,0,0,0,0,0]),128],linkLocal:[new s([65152,0,0,0,0,0,0,0]),10],multicast:[new s([65280,0,0,0,0,0,0,0]),8],loopback:[new s([0,0,0,0,0,0,0,1]),128],uniqueLocal:[new s([64512,0,0,0,0,0,0,0]),7],ipv4Mapped:[new s([0,0,0,0,0,65535,0,0]),96],discard:[new s([256,0,0,0,0,0,0,0]),64],rfc6145:[new s([0,0,0,0,65535,0,0,0]),96],rfc6052:[new s([100,65435,0,0,0,0,0,0]),96],"6to4":[new s([8194,0,0,0,0,0,0,0]),16],teredo:[new s([8193,0,0,0,0,0,0,0]),32],benchmarking:[new s([8193,2,0,0,0,0,0,0]),48],amt:[new s([8193,3,0,0,0,0,0,0]),32],as112v6:[[new s([8193,4,274,0,0,0,0,0]),48],[new s([9760,79,32768,0,0,0,0,0]),48]],deprecated:[new s([8193,16,0,0,0,0,0,0]),28],orchid2:[new s([8193,32,0,0,0,0,0,0]),28],droneRemoteIdProtocolEntityTags:[new s([8193,48,0,0,0,0,0,0]),28],reserved:[[new s([8193,0,0,0,0,0,0,0]),23],[new s([8193,3512,0,0,0,0,0,0]),32]]},s.prototype.isIPv4MappedAddress=function(){return this.range()==="ipv4Mapped"},s.prototype.kind=function(){return"ipv6"},s.prototype.match=function(d,g){let m;if(g===void 0&&(m=d,d=m[0],g=m[1]),d.kind()!=="ipv6")throw new Error("ipaddr: cannot match ipv6 address with non-ipv6 one");return v(this.parts,d.parts,16,g)},s.prototype.prefixLengthFromSubnetMask=function(){let d=0,g=!1,m={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,b;for(let F=7;F>=0;F-=1)if(x=this.parts[F],x in m){if(b=m[x],g&&b!==0)return null;b!==16&&(g=!0),d+=b}else return null;return 128-d},s.prototype.range=function(){return _.subnetMatch(this,this.SpecialRanges)},s.prototype.toByteArray=function(){let d,g=[],m=this.parts;for(let x=0;x<m.length;x++)d=m[x],g.push(d>>8),g.push(d&255);return g},s.prototype.toFixedLengthString=function(){let d=function(){let m=[];for(let x=0;x<this.parts.length;x++)m.push(A(this.parts[x].toString(16),4));return m}.call(this).join(":"),g="";return this.zoneId&&(g=`%${this.zoneId}`),d+g},s.prototype.toIPv4Address=function(){if(!this.isIPv4MappedAddress())throw new Error("ipaddr: trying to convert a generic ipv6 address to ipv4");let d=this.parts.slice(-2),g=d[0],m=d[1];return new _.IPv4([g>>8,g&255,m>>8,m&255])},s.prototype.toNormalizedString=function(){let d=function(){let m=[];for(let x=0;x<this.parts.length;x++)m.push(this.parts[x].toString(16));return m}.call(this).join(":"),g="";return this.zoneId&&(g=`%${this.zoneId}`),d+g},s.prototype.toRFC5952String=function(){let d=/((^|:)(0(:|$)){2,})/g,g=this.toNormalizedString(),m=0,x=-1,b;for(;b=d.exec(g);)b[0].length>x&&(m=b.index,x=b[0].length);return x<0?g:`${g.substring(0,m)}::${g.substring(m+x)}`},s.prototype.toString=function(){return this.toRFC5952String()},s}(),_.IPv6.broadcastAddressFromCIDR=function(s){try{let d=this.parseCIDR(s),g=d[0].toByteArray(),m=this.subnetMaskFromPrefixLength(d[1]).toByteArray(),x=[],b=0;for(;b<16;)x.push(parseInt(g[b],10)|parseInt(m[b],10)^255),b++;return new this(x)}catch(d){throw new Error(`ipaddr: the address does not have IPv6 CIDR format (${d})`)}},_.IPv6.isIPv6=function(s){return this.parser(s)!==null},_.IPv6.isValid=function(s){if(typeof s=="string"&&s.indexOf(":")===-1)return!1;try{let d=this.parser(s);return new this(d.parts,d.zoneId),!0}catch{return!1}},_.IPv6.isValidCIDR=function(s){if(typeof s=="string"&&s.indexOf(":")===-1)return!1;try{return this.parseCIDR(s),!0}catch{return!1}},_.IPv6.networkAddressFromCIDR=function(s){let d,g,m,x,b;try{for(d=this.parseCIDR(s),m=d[0].toByteArray(),b=this.subnetMaskFromPrefixLength(d[1]).toByteArray(),x=[],g=0;g<16;)x.push(parseInt(m[g],10)&parseInt(b[g],10)),g++;return new this(x)}catch(F){throw new Error(`ipaddr: the address does not have IPv6 CIDR format (${F})`)}},_.IPv6.parse=function(s){let d=this.parser(s);if(d.parts===null)throw new Error("ipaddr: string is not formatted like an IPv6 Address");return new this(d.parts,d.zoneId)},_.IPv6.parseCIDR=function(s){let d,g,m;if((g=s.match(/^(.+)\/(\d+)$/))&&(d=parseInt(g[2]),d>=0&&d<=128))return m=[this.parse(g[1]),d],Object.defineProperty(m,"toString",{value:o(function(){return this.join("/")},"value")}),m;throw new Error("ipaddr: string is not formatted like an IPv6 CIDR range")},_.IPv6.parser=function(s){let d,g,m,x,b,F;if(m=s.match(l.deprecatedTransitional))return this.parser(`::ffff:${m[1]}`);if(l.native.test(s))return y(s,8);if((m=s.match(l.transitional))&&(F=m[6]||"",d=m[1],m[1].endsWith("::")||(d=d.slice(0,-1)),d=y(d+F,6),d.parts)){for(b=[parseInt(m[2]),parseInt(m[3]),parseInt(m[4]),parseInt(m[5])],g=0;g<b.length;g++)if(x=b[g],!(0<=x&&x<=255))return null;return d.parts.push(b[0]<<8|b[1]),d.parts.push(b[2]<<8|b[3]),{parts:d.parts,zoneId:d.zoneId}}return null},_.IPv6.subnetMaskFromPrefixLength=function(s){if(s=parseInt(s),s<0||s>128)throw new Error("ipaddr: invalid IPv6 prefix length");let d=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],g=0,m=Math.floor(s/8);for(;g<m;)d[g]=255,g++;return m<16&&(d[m]=Math.pow(2,s%8)-1<<8-s%8),new this(d)},_.fromByteArray=function(s){let d=s.length;if(d===4)return new _.IPv4(s);if(d===16)return new _.IPv6(s);throw new Error("ipaddr: the binary input is neither an IPv6 nor IPv4 address")},_.isValid=function(s){return _.IPv6.isValid(s)||_.IPv4.isValid(s)},_.isValidCIDR=function(s){return _.IPv6.isValidCIDR(s)||_.IPv4.isValidCIDR(s)},_.parse=function(s){if(_.IPv6.isValid(s))return _.IPv6.parse(s);if(_.IPv4.isValid(s))return _.IPv4.parse(s);throw new Error("ipaddr: the address has neither IPv6 nor IPv4 format")},_.parseCIDR=function(s){try{return _.IPv6.parseCIDR(s)}catch{try{return _.IPv4.parseCIDR(s)}catch{throw new Error("ipaddr: the address has neither IPv6 nor IPv4 CIDR format")}}},_.process=function(s){let d=this.parse(s);return d.kind()==="ipv6"&&d.isIPv4MappedAddress()?d.toIPv4Address():d},_.subnetMatch=function(s,d,g){let m,x,b,F;g==null&&(g="unicast");for(x in d)if(Object.prototype.hasOwnProperty.call(d,x)){for(b=d[x],b[0]&&!(b[0]instanceof Array)&&(b=[b]),m=0;m<b.length;m++)if(F=b[m],s.kind()===F[0].kind()&&s.match.apply(s,F))return x}return g},typeof Ft<"u"&&Ft.exports?Ft.exports=_:e.ipaddr=_})(qo)});var Vi=$((KA,Bi)=>{var Fi=require("stream").Stream,rl=require("util");Bi.exports=de;function de(){this.source=null,this.dataSize=0,this.maxDataSize=1024*1024,this.pauseStream=!0,this._maxDataSizeExceeded=!1,this._released=!1,this._bufferedEvents=[]}o(de,"DelayedStream");rl.inherits(de,Fi);de.create=function(e,t){var r=new this;t=t||{};for(var n in t)r[n]=t[n];r.source=e;var i=e.emit;return e.emit=function(){return r._handleEmit(arguments),i.apply(e,arguments)},e.on("error",function(){}),r.pauseStream&&e.pause(),r};Object.defineProperty(de.prototype,"readable",{configurable:!0,enumerable:!0,get:o(function(){return this.source.readable},"get")});de.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)};de.prototype.resume=function(){this._released||this.release(),this.source.resume()};de.prototype.pause=function(){this.source.pause()};de.prototype.release=function(){this._released=!0,this._bufferedEvents.forEach(function(e){this.emit.apply(this,e)}.bind(this)),this._bufferedEvents=[]};de.prototype.pipe=function(){var e=Fi.prototype.pipe.apply(this,arguments);return this.resume(),e};de.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)};de.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 Wi=$((XA,qi)=>{var nl=require("util"),Hi=require("stream").Stream,Zi=Vi();qi.exports=X;function X(){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}o(X,"CombinedStream");nl.inherits(X,Hi);X.create=function(e){var t=new this;e=e||{};for(var r in e)t[r]=e[r];return t};X.isStreamLike=function(e){return typeof e!="function"&&typeof e!="string"&&typeof e!="boolean"&&typeof e!="number"&&!Buffer.isBuffer(e)};X.prototype.append=function(e){var t=X.isStreamLike(e);if(t){if(!(e instanceof Zi)){var r=Zi.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};X.prototype.pipe=function(e,t){return Hi.prototype.pipe.call(this,e,t),this.resume(),e};X.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}};X.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=X.isStreamLike(r);n&&(r.on("data",this._checkDataSize.bind(this)),this._handleErrors(r)),this._pipeNext(r)}.bind(this))};X.prototype._pipeNext=function(e){this._currentStream=e;var t=X.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()};X.prototype._handleErrors=function(e){var t=this;e.on("error",function(r){t._emitError(r)})};X.prototype.write=function(e){this.emit("data",e)};X.prototype.pause=function(){this.pauseStreams&&(this.pauseStreams&&this._currentStream&&typeof this._currentStream.pause=="function"&&this._currentStream.pause(),this.emit("pause"))};X.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")};X.prototype.end=function(){this._reset(),this.emit("end")};X.prototype.destroy=function(){this._reset(),this.emit("close")};X.prototype._reset=function(){this.writable=!1,this._streams=[],this._currentStream=null};X.prototype._checkDataSize=function(){if(this._updateDataSize(),!(this.dataSize<=this.maxDataSize)){var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(new Error(e))}};X.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)};X.prototype._emitError=function(e){this._reset(),this.emit("error",e)}});var Ki=$((QA,Gi)=>{"use strict";Gi.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 Yi=$(ne=>{"use strict";var Kt=Ki(),ol=require("path").extname,Ji=/^\s*([^;\s]*)(?:;|\s|$)/,il=/^text\//i;ne.charset=Xi;ne.charsets={lookup:Xi};ne.contentType=al;ne.extension=sl;ne.extensions=Object.create(null);ne.lookup=ul;ne.types=Object.create(null);cl(ne.extensions,ne.types);function Xi(e){if(!e||typeof e!="string")return!1;var t=Ji.exec(e),r=t&&Kt[t[1].toLowerCase()];return r&&r.charset?r.charset:t&&il.test(t[1])?"UTF-8":!1}o(Xi,"charset");function al(e){if(!e||typeof e!="string")return!1;var t=e.indexOf("/")===-1?ne.lookup(e):e;if(!t)return!1;if(t.indexOf("charset")===-1){var r=ne.charset(t);r&&(t+="; charset="+r.toLowerCase())}return t}o(al,"contentType");function sl(e){if(!e||typeof e!="string")return!1;var t=Ji.exec(e),r=t&&ne.extensions[t[1].toLowerCase()];return!r||!r.length?!1:r[0]}o(sl,"extension");function ul(e){if(!e||typeof e!="string")return!1;var t=ol("x."+e).toLowerCase().substr(1);return t&&ne.types[t]||!1}o(ul,"lookup");function cl(e,t){var r=["nginx","apache",void 0,"iana"];Object.keys(Kt).forEach(o(function(i){var u=Kt[i],c=u.extensions;if(!(!c||!c.length)){e[i]=c;for(var l=0;l<c.length;l++){var y=c[l];if(t[y]){var v=r.indexOf(Kt[t[y]].source),P=r.indexOf(u.source);if(t[y]!=="application/octet-stream"&&(v>P||v===P&&t[y].substr(0,12)==="application/"))continue}t[y]=i}}},"forEachMimeType"))}o(cl,"populateMaps")});var ea=$((rz,Qi)=>{Qi.exports=pl;function pl(e){var t=typeof setImmediate=="function"?setImmediate:typeof process=="object"&&typeof process.nextTick=="function"?process.nextTick:null;t?t(e):setTimeout(e,0)}o(pl,"defer")});var Wr=$((oz,ra)=>{var ta=ea();ra.exports=ll;function ll(e){var t=!1;return ta(function(){t=!0}),o(function(n,i){t?e(n,i):ta(o(function(){e(n,i)},"nextTick_callback"))},"async_callback")}o(ll,"async")});var Gr=$((az,na)=>{na.exports=dl;function dl(e){Object.keys(e.jobs).forEach(ml.bind(e)),e.jobs={}}o(dl,"abort");function ml(e){typeof this.jobs[e]=="function"&&this.jobs[e]()}o(ml,"clean")});var Kr=$((uz,ia)=>{var oa=Wr(),fl=Gr();ia.exports=gl;function gl(e,t,r,n){var i=r.keyedList?r.keyedList[r.index]:r.index;r.jobs[i]=yl(t,i,e[i],function(u,c){i in r.jobs&&(delete r.jobs[i],u?fl(r):r.results[i]=c,n(u,r.results))})}o(gl,"iterate");function yl(e,t,r,n){var i;return e.length==2?i=e(r,oa(n)):i=e(r,t,oa(n)),i}o(yl,"runJob")});var Jr=$((pz,aa)=>{aa.exports=hl;function hl(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(i,u){return t(e[i],e[u])}),n}o(hl,"state")});var Xr=$((dz,sa)=>{var vl=Gr(),xl=Wr();sa.exports=_l;function _l(e){Object.keys(this.jobs).length&&(this.index=this.size,vl(this),xl(e)(null,this.results))}o(_l,"terminator")});var ca=$((fz,ua)=>{var Pl=Kr(),bl=Jr(),Tl=Xr();ua.exports=Il;function Il(e,t,r){for(var n=bl(e);n.index<(n.keyedList||e).length;)Pl(e,t,n,function(i,u){if(i){r(i,u);return}if(Object.keys(n.jobs).length===0){r(null,n.results);return}}),n.index++;return Tl.bind(n,r)}o(Il,"parallel")});var Yr=$((yz,Jt)=>{var pa=Kr(),El=Jr(),Sl=Xr();Jt.exports=$l;Jt.exports.ascending=la;Jt.exports.descending=Al;function $l(e,t,r,n){var i=El(e,r);return pa(e,t,i,o(function u(c,l){if(c){n(c,l);return}if(i.index++,i.index<(i.keyedList||e).length){pa(e,t,i,u);return}n(null,i.results)},"iteratorHandler")),Sl.bind(i,n)}o($l,"serialOrdered");function la(e,t){return e<t?-1:e>t?1:0}o(la,"ascending");function Al(e,t){return-1*la(e,t)}o(Al,"descending")});var ma=$((vz,da)=>{var zl=Yr();da.exports=wl;function wl(e,t,r){return zl(e,t,null,r)}o(wl,"serial")});var ga=$((_z,fa)=>{fa.exports={parallel:ca(),serial:ma(),serialOrdered:Yr()}});var Qr=$((Pz,ya)=>{"use strict";ya.exports=Object});var va=$((bz,ha)=>{"use strict";ha.exports=Error});var _a=$((Tz,xa)=>{"use strict";xa.exports=EvalError});var ba=$((Iz,Pa)=>{"use strict";Pa.exports=RangeError});var Ia=$((Ez,Ta)=>{"use strict";Ta.exports=ReferenceError});var Sa=$((Sz,Ea)=>{"use strict";Ea.exports=SyntaxError});var Xt=$(($z,$a)=>{"use strict";$a.exports=TypeError});var za=$((Az,Aa)=>{"use strict";Aa.exports=URIError});var ka=$((zz,wa)=>{"use strict";wa.exports=Math.abs});var Na=$((wz,Oa)=>{"use strict";Oa.exports=Math.floor});var Ca=$((kz,Ra)=>{"use strict";Ra.exports=Math.max});var Ua=$((Oz,Da)=>{"use strict";Da.exports=Math.min});var ja=$((Nz,Ma)=>{"use strict";Ma.exports=Math.pow});var Fa=$((Rz,La)=>{"use strict";La.exports=Math.round});var Va=$((Cz,Ba)=>{"use strict";Ba.exports=Number.isNaN||o(function(t){return t!==t},"isNaN")});var Ha=$((Uz,Za)=>{"use strict";var kl=Va();Za.exports=o(function(t){return kl(t)||t===0?t:t<0?-1:1},"sign")});var Wa=$((jz,qa)=>{"use strict";qa.exports=Object.getOwnPropertyDescriptor});var en=$((Lz,Ga)=>{"use strict";var Yt=Wa();if(Yt)try{Yt([],"length")}catch{Yt=null}Ga.exports=Yt});var Ja=$((Fz,Ka)=>{"use strict";var Qt=Object.defineProperty||!1;if(Qt)try{Qt({},"a",{value:1})}catch{Qt=!1}Ka.exports=Qt});var tn=$((Bz,Xa)=>{"use strict";Xa.exports=o(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 i=42;t[r]=i;for(var u 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 c=Object.getOwnPropertySymbols(t);if(c.length!==1||c[0]!==r||!Object.prototype.propertyIsEnumerable.call(t,r))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var l=Object.getOwnPropertyDescriptor(t,r);if(l.value!==i||l.enumerable!==!0)return!1}return!0},"hasSymbols")});var es=$((Zz,Qa)=>{"use strict";var Ya=typeof Symbol<"u"&&Symbol,Ol=tn();Qa.exports=o(function(){return typeof Ya!="function"||typeof Symbol!="function"||typeof Ya("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:Ol()},"hasNativeSymbols")});var rn=$((qz,ts)=>{"use strict";ts.exports=typeof Reflect<"u"&&Reflect.getPrototypeOf||null});var nn=$((Wz,rs)=>{"use strict";var Nl=Qr();rs.exports=Nl.getPrototypeOf||null});var is=$((Gz,os)=>{"use strict";var Rl="Function.prototype.bind called on incompatible ",Cl=Object.prototype.toString,Dl=Math.max,Ul="[object Function]",ns=o(function(t,r){for(var n=[],i=0;i<t.length;i+=1)n[i]=t[i];for(var u=0;u<r.length;u+=1)n[u+t.length]=r[u];return n},"concatty"),Ml=o(function(t,r){for(var n=[],i=r||0,u=0;i<t.length;i+=1,u+=1)n[u]=t[i];return n},"slicy"),jl=o(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");os.exports=o(function(t){var r=this;if(typeof r!="function"||Cl.apply(r)!==Ul)throw new TypeError(Rl+r);for(var n=Ml(arguments,1),i,u=o(function(){if(this instanceof i){var P=r.apply(this,ns(n,arguments));return Object(P)===P?P:this}return r.apply(t,ns(n,arguments))},"binder"),c=Dl(0,r.length-n.length),l=[],y=0;y<c;y++)l[y]="$"+y;if(i=Function("binder","return function ("+jl(l,",")+"){ return binder.apply(this,arguments); }")(u),r.prototype){var v=o(function(){},"Empty");v.prototype=r.prototype,i.prototype=new v,v.prototype=null}return i},"bind")});var He=$((Jz,as)=>{"use strict";var Ll=is();as.exports=Function.prototype.bind||Ll});var er=$((Xz,ss)=>{"use strict";ss.exports=Function.prototype.call});var on=$((Yz,us)=>{"use strict";us.exports=Function.prototype.apply});var ps=$((Qz,cs)=>{"use strict";cs.exports=typeof Reflect<"u"&&Reflect&&Reflect.apply});var ds=$((ew,ls)=>{"use strict";var Fl=He(),Bl=on(),Vl=er(),Zl=ps();ls.exports=Zl||Fl.call(Vl,Bl)});var fs=$((tw,ms)=>{"use strict";var Hl=He(),ql=Xt(),Wl=er(),Gl=ds();ms.exports=o(function(t){if(t.length<1||typeof t[0]!="function")throw new ql("a function is required");return Gl(Hl,Wl,t)},"callBindBasic")});var _s=$((nw,xs)=>{"use strict";var Kl=fs(),gs=en(),hs;try{hs=[].__proto__===Array.prototype}catch(e){if(!e||typeof e!="object"||!("code"in e)||e.code!=="ERR_PROTO_ACCESS")throw e}var an=!!hs&&gs&&gs(Object.prototype,"__proto__"),vs=Object,ys=vs.getPrototypeOf;xs.exports=an&&typeof an.get=="function"?Kl([an.get]):typeof ys=="function"?o(function(t){return ys(t==null?t:vs(t))},"getDunder"):!1});var Es=$((iw,Is)=>{"use strict";var Ps=rn(),bs=nn(),Ts=_s();Is.exports=Ps?o(function(t){return Ps(t)},"getProto"):bs?o(function(t){if(!t||typeof t!="object"&&typeof t!="function")throw new TypeError("getProto: not an object");return bs(t)},"getProto"):Ts?o(function(t){return Ts(t)},"getProto"):null});var sn=$((sw,Ss)=>{"use strict";var Jl=Function.prototype.call,Xl=Object.prototype.hasOwnProperty,Yl=He();Ss.exports=Yl.call(Jl,Xl)});var Ns=$((uw,Os)=>{"use strict";var L,Ql=Qr(),ed=va(),td=_a(),rd=ba(),nd=Ia(),Ke=Sa(),Ge=Xt(),od=za(),id=ka(),ad=Na(),sd=Ca(),ud=Ua(),cd=ja(),pd=Fa(),ld=Ha(),ws=Function,un=o(function(e){try{return ws('"use strict"; return ('+e+").constructor;")()}catch{}},"getEvalledConstructor"),xt=en(),dd=Ja(),cn=o(function(){throw new Ge},"throwTypeError"),md=xt?function(){try{return arguments.callee,cn}catch{try{return xt(arguments,"callee").get}catch{return cn}}}():cn,qe=es()(),te=Es(),fd=nn(),gd=rn(),ks=on(),_t=er(),We={},yd=typeof Uint8Array>"u"||!te?L:te(Uint8Array),Ne={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?L:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?L:ArrayBuffer,"%ArrayIteratorPrototype%":qe&&te?te([][Symbol.iterator]()):L,"%AsyncFromSyncIteratorPrototype%":L,"%AsyncFunction%":We,"%AsyncGenerator%":We,"%AsyncGeneratorFunction%":We,"%AsyncIteratorPrototype%":We,"%Atomics%":typeof Atomics>"u"?L:Atomics,"%BigInt%":typeof BigInt>"u"?L:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?L:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?L:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?L:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":ed,"%eval%":eval,"%EvalError%":td,"%Float16Array%":typeof Float16Array>"u"?L:Float16Array,"%Float32Array%":typeof Float32Array>"u"?L:Float32Array,"%Float64Array%":typeof Float64Array>"u"?L:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?L:FinalizationRegistry,"%Function%":ws,"%GeneratorFunction%":We,"%Int8Array%":typeof Int8Array>"u"?L:Int8Array,"%Int16Array%":typeof Int16Array>"u"?L:Int16Array,"%Int32Array%":typeof Int32Array>"u"?L:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":qe&&te?te(te([][Symbol.iterator]())):L,"%JSON%":typeof JSON=="object"?JSON:L,"%Map%":typeof Map>"u"?L:Map,"%MapIteratorPrototype%":typeof Map>"u"||!qe||!te?L:te(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Ql,"%Object.getOwnPropertyDescriptor%":xt,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?L:Promise,"%Proxy%":typeof Proxy>"u"?L:Proxy,"%RangeError%":rd,"%ReferenceError%":nd,"%Reflect%":typeof Reflect>"u"?L:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?L:Set,"%SetIteratorPrototype%":typeof Set>"u"||!qe||!te?L:te(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?L:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":qe&&te?te(""[Symbol.iterator]()):L,"%Symbol%":qe?Symbol:L,"%SyntaxError%":Ke,"%ThrowTypeError%":md,"%TypedArray%":yd,"%TypeError%":Ge,"%Uint8Array%":typeof Uint8Array>"u"?L:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?L:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?L:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?L:Uint32Array,"%URIError%":od,"%WeakMap%":typeof WeakMap>"u"?L:WeakMap,"%WeakRef%":typeof WeakRef>"u"?L:WeakRef,"%WeakSet%":typeof WeakSet>"u"?L:WeakSet,"%Function.prototype.call%":_t,"%Function.prototype.apply%":ks,"%Object.defineProperty%":dd,"%Object.getPrototypeOf%":fd,"%Math.abs%":id,"%Math.floor%":ad,"%Math.max%":sd,"%Math.min%":ud,"%Math.pow%":cd,"%Math.round%":pd,"%Math.sign%":ld,"%Reflect.getPrototypeOf%":gd};if(te)try{null.error}catch(e){$s=te(te(e)),Ne["%Error.prototype%"]=$s}var $s,hd=o(function e(t){var r;if(t==="%AsyncFunction%")r=un("async function () {}");else if(t==="%GeneratorFunction%")r=un("function* () {}");else if(t==="%AsyncGeneratorFunction%")r=un("async function* () {}");else if(t==="%AsyncGenerator%"){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if(t==="%AsyncIteratorPrototype%"){var i=e("%AsyncGenerator%");i&&te&&(r=te(i.prototype))}return Ne[t]=r,r},"doEval"),As={__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"]},Pt=He(),tr=sn(),vd=Pt.call(_t,Array.prototype.concat),xd=Pt.call(ks,Array.prototype.splice),zs=Pt.call(_t,String.prototype.replace),rr=Pt.call(_t,String.prototype.slice),_d=Pt.call(_t,RegExp.prototype.exec),Pd=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,bd=/\\(\\)?/g,Td=o(function(t){var r=rr(t,0,1),n=rr(t,-1);if(r==="%"&&n!=="%")throw new Ke("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&r!=="%")throw new Ke("invalid intrinsic syntax, expected opening `%`");var i=[];return zs(t,Pd,function(u,c,l,y){i[i.length]=l?zs(y,bd,"$1"):c||u}),i},"stringToPath"),Id=o(function(t,r){var n=t,i;if(tr(As,n)&&(i=As[n],n="%"+i[0]+"%"),tr(Ne,n)){var u=Ne[n];if(u===We&&(u=hd(n)),typeof u>"u"&&!r)throw new Ge("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:i,name:n,value:u}}throw new Ke("intrinsic "+t+" does not exist!")},"getBaseIntrinsic");Os.exports=o(function(t,r){if(typeof t!="string"||t.length===0)throw new Ge("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof r!="boolean")throw new Ge('"allowMissing" argument must be a boolean');if(_d(/^%?[^%]*%?$/,t)===null)throw new Ke("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=Td(t),i=n.length>0?n[0]:"",u=Id("%"+i+"%",r),c=u.name,l=u.value,y=!1,v=u.alias;v&&(i=v[0],xd(n,vd([0,1],v)));for(var P=1,A=!0;P<n.length;P+=1){var _=n[P],s=rr(_,0,1),d=rr(_,-1);if((s==='"'||s==="'"||s==="`"||d==='"'||d==="'"||d==="`")&&s!==d)throw new Ke("property names with quotes must have matching quotes");if((_==="constructor"||!A)&&(y=!0),i+="."+_,c="%"+i+"%",tr(Ne,c))l=Ne[c];else if(l!=null){if(!(_ in l)){if(!r)throw new Ge("base intrinsic for "+t+" exists, but the property is not available.");return}if(xt&&P+1>=n.length){var g=xt(l,_);A=!!g,A&&"get"in g&&!("originalValue"in g.get)?l=g.get:l=l[_]}else A=tr(l,_),l=l[_];A&&!y&&(Ne[c]=l)}}return l},"GetIntrinsic")});var Cs=$((pw,Rs)=>{"use strict";var Ed=tn();Rs.exports=o(function(){return Ed()&&!!Symbol.toStringTag},"hasToStringTagShams")});var Ms=$((dw,Us)=>{"use strict";var Sd=Ns(),Ds=Sd("%Object.defineProperty%",!0),$d=Cs()(),Ad=sn(),zd=Xt(),nr=$d?Symbol.toStringTag:null;Us.exports=o(function(t,r){var n=arguments.length>2&&!!arguments[2]&&arguments[2].force,i=arguments.length>2&&!!arguments[2]&&arguments[2].nonConfigurable;if(typeof n<"u"&&typeof n!="boolean"||typeof i<"u"&&typeof i!="boolean")throw new zd("if provided, the `overrideIfSet` and `nonConfigurable` options must be booleans");nr&&(n||!Ad(t,nr))&&(Ds?Ds(t,nr,{configurable:!i,enumerable:!1,value:r,writable:!1}):t[nr]=r)},"setToStringTag")});var Ls=$((fw,js)=>{"use strict";var wd=Function.prototype.call,kd=Object.prototype.hasOwnProperty,Od=He();js.exports=Od.call(wd,kd)});var Bs=$((gw,Fs)=>{"use strict";Fs.exports=function(e,t){return Object.keys(t).forEach(function(r){e[r]=e[r]||t[r]}),e}});var Hs=$((yw,Zs)=>{"use strict";var mn=Wi(),Nd=require("util"),pn=require("path"),Rd=require("http"),Cd=require("https"),Dd=require("url").parse,Ud=require("fs"),Md=require("stream").Stream,jd=require("crypto"),ln=Yi(),Ld=ga(),Fd=Ms(),Ae=Ls(),dn=Bs();function Vs(e){return String(e).replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/"/g,"%22")}o(Vs,"escapeHeaderParam");function B(e){if(!(this instanceof B))return new B(e);this._overheadLength=0,this._valueLength=0,this._valuesToMeasure=[],mn.call(this),e=e||{};for(var t in e)this[t]=e[t]}o(B,"FormData");Nd.inherits(B,mn);B.LINE_BREAK=`\r
|
|
2
|
-
`;B.DEFAULT_CONTENT_TYPE="application/octet-stream";B.prototype.append=function(e,t,r){r=r||{},typeof r=="string"&&(r={filename:r});var n=mn.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 i=this._multiPartHeader(e,t,r),u=this._multiPartFooter();n(i),n(t),n(u),this._trackLength(i,t,r)};B.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)+B.LINE_BREAK.length,!(!t||!t.path&&!(t.readable&&Ae(t,"httpVersion"))&&!(t instanceof Md))&&(r.knownLength||this._valuesToMeasure.push(t))};B.prototype._lengthRetriever=function(e,t){Ae(e,"fd")?e.end!=null&&e.end!=1/0&&e.start!=null?t(null,e.end+1-(e.start?e.start:0)):Ud.stat(e.path,function(r,n){if(r){t(r);return}var i=n.size-(e.start?e.start:0);t(null,i)}):Ae(e,"httpVersion")?t(null,Number(e.headers["content-length"])):Ae(e,"httpModule")?(e.on("response",function(r){e.pause(),t(null,Number(r.headers["content-length"]))}),e.resume()):t("Unknown stream")};B.prototype._multiPartHeader=function(e,t,r){if(typeof r.header=="string")return r.header;var n=this._getContentDisposition(t,r),i=this._getContentType(t,r),u="",c={"Content-Disposition":["form-data",'name="'+Vs(e)+'"'].concat(n||[]),"Content-Type":[].concat(i||[])};typeof r.header=="object"&&dn(c,r.header);var l;for(var y in c)if(Ae(c,y)){if(l=c[y],l==null)continue;Array.isArray(l)||(l=[l]),l.length&&(u+=y+": "+l.join("; ")+B.LINE_BREAK)}return"--"+this.getBoundary()+B.LINE_BREAK+u+B.LINE_BREAK};B.prototype._getContentDisposition=function(e,t){var r;if(typeof t.filepath=="string"?r=pn.normalize(t.filepath).replace(/\\/g,"/"):t.filename||e&&(e.name||e.path)?r=pn.basename(t.filename||e&&(e.name||e.path)):e&&e.readable&&Ae(e,"httpVersion")&&(r=pn.basename(e.client._httpMessage.path||"")),r)return'filename="'+Vs(r)+'"'};B.prototype._getContentType=function(e,t){var r=t.contentType;return!r&&e&&e.name&&(r=ln.lookup(e.name)),!r&&e&&e.path&&(r=ln.lookup(e.path)),!r&&e&&e.readable&&Ae(e,"httpVersion")&&(r=e.headers["content-type"]),!r&&(t.filepath||t.filename)&&(r=ln.lookup(t.filepath||t.filename)),!r&&e&&typeof e=="object"&&(r=B.DEFAULT_CONTENT_TYPE),r};B.prototype._multiPartFooter=function(){return function(e){var t=B.LINE_BREAK,r=this._streams.length===0;r&&(t+=this._lastBoundary()),e(t)}.bind(this)};B.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+B.LINE_BREAK};B.prototype.getHeaders=function(e){var t,r={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(t in e)Ae(e,t)&&(r[t.toLowerCase()]=e[t]);return r};B.prototype.setBoundary=function(e){if(typeof e!="string")throw new TypeError("FormData boundary must be a string");this._boundary=e};B.prototype.getBoundary=function(){return this._boundary||this._generateBoundary(),this._boundary};B.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(B.LINE_BREAK)])));return Buffer.concat([e,Buffer.from(this._lastBoundary())])};B.prototype._generateBoundary=function(){this._boundary="--------------------------"+jd.randomBytes(12).toString("hex")};B.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};B.prototype.hasKnownLength=function(){var e=!0;return this._valuesToMeasure.length&&(e=!1),e};B.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}Ld.parallel(this._valuesToMeasure,this._lengthRetriever,function(r,n){if(r){e(r);return}n.forEach(function(i){t+=i}),e(null,t)})};B.prototype.submit=function(e,t){var r,n,i={method:"post"};return typeof e=="string"?(e=Dd(e),n=dn({port:e.port,path:e.pathname,host:e.hostname,protocol:e.protocol},i)):(n=dn(e,i),n.port||(n.port=n.protocol==="https:"?443:80)),n.headers=this.getHeaders(e.headers),n.protocol==="https:"?r=Cd.request(n):r=Rd.request(n),this.getLength(function(u,c){if(u&&u!=="Unknown stream"){this._error(u);return}if(c&&r.setHeader("Content-Length",c),this.pipe(r),t){var l,y=o(function(v,P){return r.removeListener("error",y),r.removeListener("response",l),t.call(this,v,P)},"callback");l=y.bind(this,null),r.on("error",y),r.on("response",l)}}.bind(this)),r};B.prototype._error=function(e){this.error||(this.error=e,this.pause(),this.emit("error",e))};B.prototype.toString=function(){return"[object FormData]"};Fd(B.prototype,"FormData");Zs.exports=B});var vm={};An(vm,{bigcommerce:()=>hm});module.exports=$u(vm);var Au=Object.freeze({status:"aborted"});function E(e,t,r){function n(l,y){if(l._zod||Object.defineProperty(l,"_zod",{value:{def:y,constr:c,traits:new Set},enumerable:!1}),l._zod.traits.has(e))return;l._zod.traits.add(e),t(l,y);let v=c.prototype,P=Object.keys(v);for(let A=0;A<P.length;A++){let _=P[A];_ in l||(l[_]=v[_].bind(l))}}o(n,"init");let i=r?.Parent??Object;class u extends i{static{o(this,"Definition")}}Object.defineProperty(u,"name",{value:e});function c(l){var y;let v=r?.Parent?new u:this;n(v,l),(y=v._zod).deferred??(y.deferred=[]);for(let P of v._zod.deferred)P();return v}return o(c,"_"),Object.defineProperty(c,"init",{value:n}),Object.defineProperty(c,Symbol.hasInstance,{value:o(l=>r?.Parent&&l instanceof r.Parent?!0:l?._zod?.traits?.has(e),"value")}),Object.defineProperty(c,"name",{value:e}),c}o(E,"$constructor");var zu=Symbol("zod_brand"),me=class extends Error{static{o(this,"$ZodAsyncError")}constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}},Tt=class extends Error{static{o(this,"$ZodEncodeError")}constructor(t){super(`Encountered unidirectional transform during encode: ${t}`),this.name="ZodEncodeError"}},ur={};function ye(e){return e&&Object.assign(ur,e),ur}o(ye,"config");function pr(e){let t=Object.values(e).filter(n=>typeof n=="number");return Object.entries(e).filter(([n,i])=>t.indexOf(+n)===-1).map(([n,i])=>i)}o(pr,"getEnumValues");function kn(e,t){return typeof t=="bigint"?t.toString():t}o(kn,"jsonStringifyReplacer");function Et(e){return{get value(){{let r=e();return Object.defineProperty(this,"value",{value:r}),r}throw new Error("cached value already set")}}}o(Et,"cached");function On(e){return e==null}o(On,"nullish");function St(e){let t=e.startsWith("^")?1:0,r=e.endsWith("$")?e.length-1:e.length;return e.slice(t,r)}o(St,"cleanRegex");var wn=Symbol("evaluating");function Y(e,t,r){let n;Object.defineProperty(e,t,{get(){if(n!==wn)return n===void 0&&(n=wn,n=r()),n},set(i){Object.defineProperty(e,t,{value:i})},configurable:!0})}o(Y,"defineLazy");var lr="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function Ye(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}o(Ye,"isObject");var wu=Et(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{let e=Function;return new e(""),!0}catch{return!1}});function Nn(e){if(Ye(e)===!1)return!1;let t=e.constructor;if(t===void 0||typeof t!="function")return!0;let r=t.prototype;return!(Ye(r)===!1||Object.prototype.hasOwnProperty.call(r,"isPrototypeOf")===!1)}o(Nn,"isPlainObject");var Rn=new Set(["string","number","symbol"]);function De(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}o(De,"escapeRegex");function $t(e,t,r){let n=new e._zod.constr(t??e._zod.def);return(!t||r?.parent)&&(n._zod.parent=e),n}o($t,"clone");function W(e){let t=e;if(!t)return{};if(typeof t=="string")return{error:o(()=>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:o(()=>t.error,"error")}:t}o(W,"normalizeParams");function Cn(e){return Object.keys(e).filter(t=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}o(Cn,"optionalKeys");var ku={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 Ue(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}o(Ue,"aborted");function be(e,t){return t.map(r=>{var n;return(n=r).path??(n.path=[]),r.path.unshift(e),r})}o(be,"prefixIssues");function It(e){return typeof e=="string"?e:e?.message}o(It,"unwrapMessage");function Te(e,t,r){let n={...e,path:e.path??[]};if(!e.message){let i=It(e.inst?._zod.def?.error?.(e))??It(t?.error?.(e))??It(r.customError?.(e))??It(r.localeError?.(e))??"Invalid input";n.message=i}return delete n.inst,delete n.continue,t?.reportInput||delete n.input,n}o(Te,"finalizeIssue");function Dn(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}o(Dn,"getLengthableOrigin");function dr(...e){let[t,r,n]=e;return typeof t=="string"?{message:t,code:"custom",input:r,inst:n}:{...t}}o(dr,"issue");var Un=o((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,kn,2),Object.defineProperty(e,"toString",{value:o(()=>e.message,"value"),enumerable:!1})},"initializer"),Mn=E("$ZodError",Un),Qe=E("$ZodError",Un,{Parent:Error});var Nu=o(e=>(t,r,n,i)=>{let u=n?Object.assign(n,{async:!1}):{async:!1},c=t._zod.run({value:r,issues:[]},u);if(c instanceof Promise)throw new me;if(c.issues.length){let l=new(i?.Err??e)(c.issues.map(y=>Te(y,u,ye())));throw lr(l,i?.callee),l}return c.value},"_parse"),At=Nu(Qe),Ru=o(e=>async(t,r,n,i)=>{let u=n?Object.assign(n,{async:!0}):{async:!0},c=t._zod.run({value:r,issues:[]},u);if(c instanceof Promise&&(c=await c),c.issues.length){let l=new(i?.Err??e)(c.issues.map(y=>Te(y,u,ye())));throw lr(l,i?.callee),l}return c.value},"_parseAsync"),zt=Ru(Qe),Cu=o(e=>(t,r,n)=>{let i=n?{...n,async:!1}:{async:!1},u=t._zod.run({value:r,issues:[]},i);if(u instanceof Promise)throw new me;return u.issues.length?{success:!1,error:new(e??Mn)(u.issues.map(c=>Te(c,i,ye())))}:{success:!0,data:u.value}},"_safeParse"),et=Cu(Qe),Du=o(e=>async(t,r,n)=>{let i=n?Object.assign(n,{async:!0}):{async:!0},u=t._zod.run({value:r,issues:[]},i);return u instanceof Promise&&(u=await u),u.issues.length?{success:!1,error:new e(u.issues.map(c=>Te(c,i,ye())))}:{success:!0,data:u.value}},"_safeParseAsync"),tt=Du(Qe);var Uu="(?:(?:\\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])))",Mu=new RegExp(`^${Uu}$`);var jn=o(e=>{let t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)},"string"),Ln=/^-?\d+n?$/;var mr=/^-?\d+(?:\.\d+)?$/,Fn=/^(?:true|false)$/i;var Me=E("$ZodCheck",(e,t)=>{var r;e._zod??(e._zod={}),e._zod.def=t,(r=e._zod).onattach??(r.onattach=[])});var Bn=E("$ZodCheckMinLength",(e,t)=>{var r;Me.init(e,t),(r=e._zod.def).when??(r.when=n=>{let i=n.value;return!On(i)&&i.length!==void 0}),e._zod.onattach.push(n=>{let i=n._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>i&&(n._zod.bag.minimum=t.minimum)}),e._zod.check=n=>{let i=n.value;if(i.length>=t.minimum)return;let c=Dn(i);n.issues.push({origin:c,code:"too_small",minimum:t.minimum,inclusive:!0,input:i,inst:e,continue:!t.abort})}});var fr=E("$ZodCheckStringFormat",(e,t)=>{var r,n;Me.init(e,t),e._zod.onattach.push(i=>{let u=i._zod.bag;u.format=t.format,t.pattern&&(u.patterns??(u.patterns=new Set),u.patterns.add(t.pattern))}),t.pattern?(r=e._zod).check??(r.check=i=>{t.pattern.lastIndex=0,!t.pattern.test(i.value)&&i.issues.push({origin:"string",code:"invalid_format",format:t.format,input:i.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(n=e._zod).check??(n.check=()=>{})}),Vn=E("$ZodCheckRegex",(e,t)=>{fr.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 Hn={major:4,minor:3,patch:6};var G=E("$ZodType",(e,t)=>{var r;e??(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=Hn;let n=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&n.unshift(e);for(let i of n)for(let u of i._zod.onattach)u(e);if(n.length===0)(r=e._zod).deferred??(r.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{let i=o((c,l,y)=>{let v=Ue(c),P;for(let A of l){if(A._zod.def.when){if(!A._zod.def.when(c))continue}else if(v)continue;let _=c.issues.length,s=A._zod.check(c);if(s instanceof Promise&&y?.async===!1)throw new me;if(P||s instanceof Promise)P=(P??Promise.resolve()).then(async()=>{await s,c.issues.length!==_&&(v||(v=Ue(c,_)))});else{if(c.issues.length===_)continue;v||(v=Ue(c,_))}}return P?P.then(()=>c):c},"runChecks"),u=o((c,l,y)=>{if(Ue(c))return c.aborted=!0,c;let v=i(l,n,y);if(v instanceof Promise){if(y.async===!1)throw new me;return v.then(P=>e._zod.parse(P,y))}return e._zod.parse(v,y)},"handleCanaryResult");e._zod.run=(c,l)=>{if(l.skipChecks)return e._zod.parse(c,l);if(l.direction==="backward"){let v=e._zod.parse({value:c.value,issues:[]},{...l,skipChecks:!0});return v instanceof Promise?v.then(P=>u(P,c,l)):u(v,c,l)}let y=e._zod.parse(c,l);if(y instanceof Promise){if(l.async===!1)throw new me;return y.then(v=>i(v,n,l))}return i(y,n,l)}}Y(e,"~standard",()=>({validate:o(i=>{try{let u=et(e,i);return u.success?{value:u.data}:{issues:u.error?.issues}}catch{return tt(e,i).then(c=>c.success?{value:c.data}:{issues:c.error?.issues})}},"validate"),vendor:"zod",version:1}))}),Ot=E("$ZodString",(e,t)=>{G.init(e,t),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??jn(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}}),gr=E("$ZodStringFormat",(e,t)=>{fr.init(e,t),Ot.init(e,t)});var Jn=E("$ZodURL",(e,t)=>{gr.init(e,t),e._zod.check=r=>{try{let n=r.value.trim(),i=new URL(n);t.hostname&&(t.hostname.lastIndex=0,t.hostname.test(i.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(i.protocol.endsWith(":")?i.protocol.slice(0,-1):i.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=i.href:r.value=n;return}catch{r.issues.push({code:"invalid_format",format:"url",input:r.value,inst:e,continue:!t.abort})}}});var Xn=E("$ZodNumber",(e,t)=>{G.init(e,t),e._zod.pattern=e._zod.bag.pattern??mr,e._zod.parse=(r,n)=>{if(t.coerce)try{r.value=Number(r.value)}catch{}let i=r.value;if(typeof i=="number"&&!Number.isNaN(i)&&Number.isFinite(i))return r;let u=typeof i=="number"?Number.isNaN(i)?"NaN":Number.isFinite(i)?void 0:"Infinity":void 0;return r.issues.push({expected:"number",code:"invalid_type",input:i,inst:e,...u?{received:u}:{}}),r}});var yr=E("$ZodBoolean",(e,t)=>{G.init(e,t),e._zod.pattern=Fn,e._zod.parse=(r,n)=>{if(t.coerce)try{r.value=!!r.value}catch{}let i=r.value;return typeof i=="boolean"||r.issues.push({expected:"boolean",code:"invalid_type",input:i,inst:e}),r}}),Yn=E("$ZodBigInt",(e,t)=>{G.init(e,t),e._zod.pattern=Ln,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 Qn=E("$ZodAny",(e,t)=>{G.init(e,t),e._zod.parse=r=>r}),eo=E("$ZodUnknown",(e,t)=>{G.init(e,t),e._zod.parse=r=>r});var to=E("$ZodVoid",(e,t)=>{G.init(e,t),e._zod.parse=(r,n)=>{let i=r.value;return typeof i>"u"||r.issues.push({expected:"void",code:"invalid_type",input:i,inst:e}),r}}),ro=E("$ZodDate",(e,t)=>{G.init(e,t),e._zod.parse=(r,n)=>{if(t.coerce)try{r.value=new Date(r.value)}catch{}let i=r.value,u=i instanceof Date;return u&&!Number.isNaN(i.getTime())||r.issues.push({expected:"date",code:"invalid_type",input:i,...u?{received:"Invalid Date"}:{},inst:e}),r}});function qn(e,t,r){e.issues.length&&t.issues.push(...be(r,e.issues)),t.value[r]=e.value}o(qn,"handleArrayResult");var no=E("$ZodArray",(e,t)=>{G.init(e,t),e._zod.parse=(r,n)=>{let i=r.value;if(!Array.isArray(i))return r.issues.push({expected:"array",code:"invalid_type",input:i,inst:e}),r;r.value=Array(i.length);let u=[];for(let c=0;c<i.length;c++){let l=i[c],y=t.element._zod.run({value:l,issues:[]},n);y instanceof Promise?u.push(y.then(v=>qn(v,r,c))):qn(y,r,c)}return u.length?Promise.all(u).then(()=>r):r}});function kt(e,t,r,n,i){if(e.issues.length){if(i&&!(r in n))return;t.issues.push(...be(r,e.issues))}e.value===void 0?r in n&&(t.value[r]=void 0):t.value[r]=e.value}o(kt,"handlePropertyResult");function ju(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=Cn(e.shape);return{...e,keys:t,keySet:new Set(t),numKeys:t.length,optionalKeys:new Set(r)}}o(ju,"normalizeDef");function Lu(e,t,r,n,i,u){let c=[],l=i.keySet,y=i.catchall._zod,v=y.def.type,P=y.optout==="optional";for(let A in t){if(l.has(A))continue;if(v==="never"){c.push(A);continue}let _=y.run({value:t[A],issues:[]},n);_ instanceof Promise?e.push(_.then(s=>kt(s,r,A,t,P))):kt(_,r,A,t,P)}return c.length&&r.issues.push({code:"unrecognized_keys",keys:c,input:t,inst:u}),e.length?Promise.all(e).then(()=>r):r}o(Lu,"handleCatchall");var oo=E("$ZodObject",(e,t)=>{if(G.init(e,t),!Object.getOwnPropertyDescriptor(t,"shape")?.get){let l=t.shape;Object.defineProperty(t,"shape",{get:o(()=>{let y={...l};return Object.defineProperty(t,"shape",{value:y}),y},"get")})}let n=Et(()=>ju(t));Y(e._zod,"propValues",()=>{let l=t.shape,y={};for(let v in l){let P=l[v]._zod;if(P.values){y[v]??(y[v]=new Set);for(let A of P.values)y[v].add(A)}}return y});let i=Ye,u=t.catchall,c;e._zod.parse=(l,y)=>{c??(c=n.value);let v=l.value;if(!i(v))return l.issues.push({expected:"object",code:"invalid_type",input:v,inst:e}),l;l.value={};let P=[],A=c.shape;for(let _ of c.keys){let s=A[_],d=s._zod.optout==="optional",g=s._zod.run({value:v[_],issues:[]},y);g instanceof Promise?P.push(g.then(m=>kt(m,l,_,v,d))):kt(g,l,_,v,d)}return u?Lu(P,v,l,y,n.value,e):P.length?Promise.all(P).then(()=>l):l}});function Wn(e,t,r,n){for(let u of e)if(u.issues.length===0)return t.value=u.value,t;let i=e.filter(u=>!Ue(u));return i.length===1?(t.value=i[0].value,i[0]):(t.issues.push({code:"invalid_union",input:t.value,inst:r,errors:e.map(u=>u.issues.map(c=>Te(c,n,ye())))}),t)}o(Wn,"handleUnionResults");var hr=E("$ZodUnion",(e,t)=>{G.init(e,t),Y(e._zod,"optin",()=>t.options.some(i=>i._zod.optin==="optional")?"optional":void 0),Y(e._zod,"optout",()=>t.options.some(i=>i._zod.optout==="optional")?"optional":void 0),Y(e._zod,"values",()=>{if(t.options.every(i=>i._zod.values))return new Set(t.options.flatMap(i=>Array.from(i._zod.values)))}),Y(e._zod,"pattern",()=>{if(t.options.every(i=>i._zod.pattern)){let i=t.options.map(u=>u._zod.pattern);return new RegExp(`^(${i.map(u=>St(u.source)).join("|")})$`)}});let r=t.options.length===1,n=t.options[0]._zod.run;e._zod.parse=(i,u)=>{if(r)return n(i,u);let c=!1,l=[];for(let y of t.options){let v=y._zod.run({value:i.value,issues:[]},u);if(v instanceof Promise)l.push(v),c=!0;else{if(v.issues.length===0)return v;l.push(v)}}return c?Promise.all(l).then(y=>Wn(y,i,e,u)):Wn(l,i,e,u)}});var io=E("$ZodDiscriminatedUnion",(e,t)=>{t.inclusive=!1,hr.init(e,t);let r=e._zod.parse;Y(e._zod,"propValues",()=>{let i={};for(let u of t.options){let c=u._zod.propValues;if(!c||Object.keys(c).length===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(u)}"`);for(let[l,y]of Object.entries(c)){i[l]||(i[l]=new Set);for(let v of y)i[l].add(v)}}return i});let n=Et(()=>{let i=t.options,u=new Map;for(let c of i){let l=c._zod.propValues?.[t.discriminator];if(!l||l.size===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(c)}"`);for(let y of l){if(u.has(y))throw new Error(`Duplicate discriminator value "${String(y)}"`);u.set(y,c)}}return u});e._zod.parse=(i,u)=>{let c=i.value;if(!Ye(c))return i.issues.push({code:"invalid_type",expected:"object",input:c,inst:e}),i;let l=n.value.get(c?.[t.discriminator]);return l?l._zod.run(i,u):t.unionFallback?r(i,u):(i.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",discriminator:t.discriminator,input:c,path:[t.discriminator],inst:e}),i)}});var ao=E("$ZodRecord",(e,t)=>{G.init(e,t),e._zod.parse=(r,n)=>{let i=r.value;if(!Nn(i))return r.issues.push({expected:"record",code:"invalid_type",input:i,inst:e}),r;let u=[],c=t.keyType._zod.values;if(c){r.value={};let l=new Set;for(let v of c)if(typeof v=="string"||typeof v=="number"||typeof v=="symbol"){l.add(typeof v=="number"?v.toString():v);let P=t.valueType._zod.run({value:i[v],issues:[]},n);P instanceof Promise?u.push(P.then(A=>{A.issues.length&&r.issues.push(...be(v,A.issues)),r.value[v]=A.value})):(P.issues.length&&r.issues.push(...be(v,P.issues)),r.value[v]=P.value)}let y;for(let v in i)l.has(v)||(y=y??[],y.push(v));y&&y.length>0&&r.issues.push({code:"unrecognized_keys",input:i,inst:e,keys:y})}else{r.value={};for(let l of Reflect.ownKeys(i)){if(l==="__proto__")continue;let y=t.keyType._zod.run({value:l,issues:[]},n);if(y instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(typeof l=="string"&&mr.test(l)&&y.issues.length){let A=t.keyType._zod.run({value:Number(l),issues:[]},n);if(A instanceof Promise)throw new Error("Async schemas not supported in object keys currently");A.issues.length===0&&(y=A)}if(y.issues.length){t.mode==="loose"?r.value[l]=i[l]:r.issues.push({code:"invalid_key",origin:"record",issues:y.issues.map(A=>Te(A,n,ye())),input:l,path:[l],inst:e});continue}let P=t.valueType._zod.run({value:i[l],issues:[]},n);P instanceof Promise?u.push(P.then(A=>{A.issues.length&&r.issues.push(...be(l,A.issues)),r.value[y.value]=A.value})):(P.issues.length&&r.issues.push(...be(l,P.issues)),r.value[y.value]=P.value)}}return u.length?Promise.all(u).then(()=>r):r}});var so=E("$ZodEnum",(e,t)=>{G.init(e,t);let r=pr(t.entries),n=new Set(r);e._zod.values=n,e._zod.pattern=new RegExp(`^(${r.filter(i=>Rn.has(typeof i)).map(i=>typeof i=="string"?De(i):i.toString()).join("|")})$`),e._zod.parse=(i,u)=>{let c=i.value;return n.has(c)||i.issues.push({code:"invalid_value",values:r,input:c,inst:e}),i}}),uo=E("$ZodLiteral",(e,t)=>{if(G.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"?De(n):n?De(n.toString()):String(n)).join("|")})$`),e._zod.parse=(n,i)=>{let u=n.value;return r.has(u)||n.issues.push({code:"invalid_value",values:t.values,input:u,inst:e}),n}});var co=E("$ZodTransform",(e,t)=>{G.init(e,t),e._zod.parse=(r,n)=>{if(n.direction==="backward")throw new Tt(e.constructor.name);let i=t.transform(r.value,r);if(n.async)return(i instanceof Promise?i:Promise.resolve(i)).then(c=>(r.value=c,r));if(i instanceof Promise)throw new me;return r.value=i,r}});function Gn(e,t){return e.issues.length&&t===void 0?{issues:[],value:void 0}:e}o(Gn,"handleOptionalResult");var po=E("$ZodOptional",(e,t)=>{G.init(e,t),e._zod.optin="optional",e._zod.optout="optional",Y(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,void 0]):void 0),Y(e._zod,"pattern",()=>{let r=t.innerType._zod.pattern;return r?new RegExp(`^(${St(r.source)})?$`):void 0}),e._zod.parse=(r,n)=>{if(t.innerType._zod.optin==="optional"){let i=t.innerType._zod.run(r,n);return i instanceof Promise?i.then(u=>Gn(u,r.value)):Gn(i,r.value)}return r.value===void 0?r:t.innerType._zod.run(r,n)}});var lo=E("$ZodNullable",(e,t)=>{G.init(e,t),Y(e._zod,"optin",()=>t.innerType._zod.optin),Y(e._zod,"optout",()=>t.innerType._zod.optout),Y(e._zod,"pattern",()=>{let r=t.innerType._zod.pattern;return r?new RegExp(`^(${St(r.source)}|null)$`):void 0}),Y(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 mo=E("$ZodPipe",(e,t)=>{G.init(e,t),Y(e._zod,"values",()=>t.in._zod.values),Y(e._zod,"optin",()=>t.in._zod.optin),Y(e._zod,"optout",()=>t.out._zod.optout),Y(e._zod,"propValues",()=>t.in._zod.propValues),e._zod.parse=(r,n)=>{if(n.direction==="backward"){let u=t.out._zod.run(r,n);return u instanceof Promise?u.then(c=>wt(c,t.in,n)):wt(u,t.in,n)}let i=t.in._zod.run(r,n);return i instanceof Promise?i.then(u=>wt(u,t.out,n)):wt(i,t.out,n)}});function wt(e,t,r){return e.issues.length?(e.aborted=!0,e):t._zod.run({value:e.value,issues:e.issues},r)}o(wt,"handlePipeResult");var fo=E("$ZodCustom",(e,t)=>{Me.init(e,t),G.init(e,t),e._zod.parse=(r,n)=>r,e._zod.check=r=>{let n=r.value,i=t.fn(n);if(i instanceof Promise)return i.then(u=>Kn(u,r,n,e));Kn(i,r,n,e)}});function Kn(e,t,r,n){if(!e){let i={code:"custom",input:r,inst:n,path:[...n._zod.def.path??[]],continue:!n._zod.def.abort};n._zod.def.params&&(i.params=n._zod.def.params),t.issues.push(dr(i))}}o(Kn,"handleRefineResult");var yo,Zu=Symbol("ZodOutput"),Hu=Symbol("ZodInput"),vr=class{static{o(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 i={...n,...this._map.get(t)};return Object.keys(i).length?i:void 0}return this._map.get(t)}has(t){return this._map.has(t)}};function ho(){return new vr}o(ho,"registry");(yo=globalThis).__zod_globalRegistry??(yo.__zod_globalRegistry=ho());var xr=globalThis.__zod_globalRegistry;function vo(e,t){return new e({type:"string",...W(t)})}o(vo,"_string");function xo(e,t){return new e({type:"string",coerce:!0,...W(t)})}o(xo,"_coercedString");function _o(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...W(t)})}o(_o,"_url");function Po(e,t){return new e({type:"number",checks:[],...W(t)})}o(Po,"_number");function bo(e,t){return new e({type:"number",coerce:!0,checks:[],...W(t)})}o(bo,"_coercedNumber");function To(e,t){return new e({type:"boolean",...W(t)})}o(To,"_boolean");function Io(e,t){return new e({type:"boolean",coerce:!0,...W(t)})}o(Io,"_coercedBoolean");function Eo(e,t){return new e({type:"bigint",coerce:!0,...W(t)})}o(Eo,"_coercedBigint");function So(e){return new e({type:"any"})}o(So,"_any");function $o(e){return new e({type:"unknown"})}o($o,"_unknown");function Ao(e,t){return new e({type:"void",...W(t)})}o(Ao,"_void");function zo(e,t){return new e({type:"date",coerce:!0,...W(t)})}o(zo,"_coercedDate");function pe(e,t){return new Bn({check:"min_length",...W(t),minimum:e})}o(pe,"_minLength");function Ie(e,t){return new Vn({check:"string_format",format:"regex",...W(t),pattern:e})}o(Ie,"_regex");function wo(e,t,r){let n=W(r);return n.abort??(n.abort=!0),new e({type:"custom",check:"custom",fn:t,...n})}o(wo,"_custom");var Q=E("ZodMiniType",(e,t)=>{if(!e._zod)throw new Error("Uninitialized schema in ZodMiniType.");G.init(e,t),e.def=t,e.type=t.type,e.parse=(r,n)=>At(e,r,n,{callee:e.parse}),e.safeParse=(r,n)=>et(e,r,n),e.parseAsync=async(r,n)=>zt(e,r,n,{callee:e.parseAsync}),e.safeParseAsync=async(r,n)=>tt(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)=>$t(e,r,n),e.brand=()=>e,e.register=(r,n)=>(r.add(e,n),e),e.apply=r=>r(e)}),Rt=E("ZodMiniString",(e,t)=>{Ot.init(e,t),Q.init(e,t)});function a(e){return vo(Rt,e)}o(a,"string");var ko=E("ZodMiniStringFormat",(e,t)=>{gr.init(e,t),Rt.init(e,t)});var tc=E("ZodMiniURL",(e,t)=>{Jn.init(e,t),ko.init(e,t)});function Oo(e){return _o(tc,e)}o(Oo,"url");var _r=E("ZodMiniNumber",(e,t)=>{Xn.init(e,t),Q.init(e,t)});function re(e){return Po(_r,e)}o(re,"number");var Pr=E("ZodMiniBoolean",(e,t)=>{yr.init(e,t),Q.init(e,t)});function H(e){return To(Pr,e)}o(H,"boolean");var No=E("ZodMiniBigInt",(e,t)=>{Yn.init(e,t),Q.init(e,t)});var rc=E("ZodMiniAny",(e,t)=>{Qn.init(e,t),Q.init(e,t)});function nt(){return So(rc)}o(nt,"any");var nc=E("ZodMiniUnknown",(e,t)=>{eo.init(e,t),Q.init(e,t)});function N(){return $o(nc)}o(N,"unknown");var oc=E("ZodMiniVoid",(e,t)=>{to.init(e,t),Q.init(e,t)});function Ro(e){return Ao(oc,e)}o(Ro,"_void");var Co=E("ZodMiniDate",(e,t)=>{ro.init(e,t),Q.init(e,t)});var ic=E("ZodMiniArray",(e,t)=>{no.init(e,t),Q.init(e,t)});function D(e,t){return new ic({type:"array",element:e,...W(t)})}o(D,"array");var ac=E("ZodMiniObject",(e,t)=>{oo.init(e,t),Q.init(e,t),Y(e,"shape",()=>t.shape)});function p(e,t){let r={type:"object",shape:e??{},...W(t)};return new ac(r)}o(p,"object");var sc=E("ZodMiniUnion",(e,t)=>{hr.init(e,t),Q.init(e,t)});function U(e,t){return new sc({type:"union",options:e,...W(t)})}o(U,"union");var uc=E("ZodMiniDiscriminatedUnion",(e,t)=>{io.init(e,t),Q.init(e,t)});function je(e,t,r){return new uc({type:"union",options:t,discriminator:e,...W(r)})}o(je,"discriminatedUnion");var cc=E("ZodMiniRecord",(e,t)=>{ao.init(e,t),Q.init(e,t)});function R(e,t,r){return new cc({type:"record",keyType:e,valueType:t,...W(r)})}o(R,"record");var pc=E("ZodMiniEnum",(e,t)=>{so.init(e,t),Q.init(e,t),e.options=Object.values(t.entries)});function j(e,t){let r=Array.isArray(e)?Object.fromEntries(e.map(n=>[n,n])):e;return new pc({type:"enum",entries:r,...W(t)})}o(j,"_enum");var lc=E("ZodMiniLiteral",(e,t)=>{uo.init(e,t),Q.init(e,t)});function z(e,t){return new lc({type:"literal",values:Array.isArray(e)?e:[e],...W(t)})}o(z,"literal");var dc=E("ZodMiniTransform",(e,t)=>{co.init(e,t),Q.init(e,t)});function Ee(e){return new dc({type:"transform",transform:e})}o(Ee,"transform");var mc=E("ZodMiniOptional",(e,t)=>{po.init(e,t),Q.init(e,t)});function h(e){return new mc({type:"optional",innerType:e})}o(h,"optional");var fc=E("ZodMiniNullable",(e,t)=>{lo.init(e,t),Q.init(e,t)});function ot(e){return new fc({type:"nullable",innerType:e})}o(ot,"nullable");var gc=E("ZodMiniPipe",(e,t)=>{mo.init(e,t),Q.init(e,t)});function Se(e,t){return new gc({type:"pipe",in:e,out:t})}o(Se,"pipe");var yc=E("ZodMiniCustom",(e,t)=>{fo.init(e,t),Q.init(e,t)});function Ct(e,t){return wo(yc,e??(()=>!0),t)}o(Ct,"custom");var it={};An(it,{bigint:()=>Tc,boolean:()=>bc,date:()=>Ic,number:()=>Pc,string:()=>_c});function _c(e){return xo(Rt,e)}o(_c,"string");function Pc(e){return bo(_r,e)}o(Pc,"number");function bc(e){return Io(Pr,e)}o(bc,"boolean");function Tc(e){return Eo(No,e)}o(Tc,"bigint");function Ic(e){return zo(Co,e)}o(Ic,"date");var Tr=p({retryOnFailure:p({defaultValue:h(H()),hide:h(H())}),continueOnFailure:p({defaultValue:h(H()),hide:h(H())})}),br=class{constructor(t,r,n,i,u,c,l,y,v,P,A){this.name=t;this.displayName=r;this.description=n;this.props=i;this.run=u;this.test=c;this.requireAuth=l;this.errorHandlingOptions=y;this.outputSchema=v;this.audience=P;this.aiMetadata=A}static{o(this,"IAction")}},V=o(e=>new br(e.name,e.displayName,e.description,e.props,e.run,e.test??e.run,e.requireAuth??!0,e.errorHandlingOptions??{continueOnFailure:{defaultValue:!1},retryOnFailure:{defaultValue:!1}},e.outputSchema,e.audience,e.aiMetadata),"createAction");var Z=p({displayName:a(),description:h(a())}),M=o((e,t)=>p({type:z(t),required:H(),defaultValue:h(nt())}),"TPropertyValue");var ae=p({...Z.shape,...M(a(),"SHORT_TEXT").shape}),he=p({...Z.shape,...M(a(),"LONG_TEXT").shape});var Uo=p({label:a(),value:N()}),Dt=p({disabled:h(H()),placeholder:h(a()),options:D(Uo)});var se=p({...Z.shape,options:Dt,...M(N(),"STATIC_DROPDOWN").shape}),ve=p({...Z.shape,options:Dt,...M(D(N()),"STATIC_MULTI_SELECT_DROPDOWN").shape});var Ir=p({...Z.shape,...M(N(),"DROPDOWN").shape,refreshers:D(a())}),at=p({...Z.shape,...M(D(N()),"MULTI_SELECT_DROPDOWN").shape,refreshers:D(a())});var xe=p({...Z.shape,...M(H(),"CHECKBOX").shape});var _e=p({...Z.shape,...M(re(),"NUMBER").shape});var st=p({...Z.shape,...M(N(),"FILE").shape});var ut=p({...Z.shape,...M(a(),"DATE_TIME").shape});var Mo=R(a(),U([ae,he,se,at,ve,xe,_e,st,ut])),ct=p({...Z.shape,properties:Mo,...M(D(N()),"ARRAY").shape});var pt=p({...Z.shape,...M(U([R(a(),N())]),"JSON").shape});var jo=U([ae,se,pt,ct,ve]),Sc=R(a(),jo),Er=p({refreshers:D(a()),...Z.shape,...M(N(),"DYNAMIC").shape});var Ut=p({...Z.shape,...M(Ro(),"MARKDOWN").shape});var lt=(r=>(r.ARCHIVE="ARCHIVE",r.REGISTRY="REGISTRY",r))(lt||{}),Le=(r=>(r.CUSTOM="CUSTOM",r.OFFICIAL="OFFICIAL",r))(Le||{}),dt=(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))(dt||{});var mt=(r=>(r.AUTHORIZATION_CODE="authorization_code",r.CLIENT_CREDENTIALS="client_credentials",r))(mt||{}),Sr="both_client_credentials_and_authorization_code";var ee=(i=>(i.POLLING="POLLING",i.WEBHOOK="WEBHOOK",i.APP_WEBHOOK="APP_WEBHOOK",i.MANUAL="MANUAL",i))(ee||{}),ft=(u=>(u.NONE="NONE",u.HEADER_PRESENT="HEADER_PRESENT",u.QUERY_PRESENT="QUERY_PRESENT",u.BODY_PARAM_PRESENT="BODY_PARAM_PRESENT",u.HEAD_REQUEST="HEAD_REQUEST",u))(ft||{}),$c=p({strategy:j(ft),paramName:h(a())}),gt=(r=>(r.SIMULATION="SIMULATION",r.TEST_FUNCTION="TEST_FUNCTION",r))(gt||{});var Mt=(r=>(r.WEBSOCKET="WEBSOCKET",r.NONE="NONE",r))(Mt||{}),Lo=p({status:h(re()),body:h(N()),headers:h(R(a(),a()))}),Fo=p({type:z("DELAY"),resumeDateTime:a(),requestIdToReply:h(a()),handlerId:h(a()),streamStepProgress:h(j(Mt))}),Bo=p({type:z("WEBHOOK"),requestId:a(),requestIdToReply:h(a()),response:Lo,handlerId:h(a()),streamStepProgress:h(j(Mt))}),Ac=U([Fo,Bo]);var zc=p({body:N(),rawBody:h(N()),headers:R(a(),a()),queryParams:R(a(),a())});function le(e){return e==null}o(le,"isNil");function yt(e){return e==null?!0:typeof e=="string"||Array.isArray(e)?e.length===0:typeof e=="object"?Object.keys(e).length===0:!1}o(yt,"isEmpty");function jt(e,t){if(e==null)throw new Error(`${t} is null or undefined`)}o(jt,"assertNotNullOrUndefined");var $r=Ce(require("crypto"),1);var wc=128,we,Fe,kc=o(e=>{!we||we.length<e?(we=Buffer.allocUnsafe(e*wc),$r.default.randomFillSync(we),Fe=0):Fe+e>we.length&&($r.default.randomFillSync(we),Fe=0),Fe+=e},"fillPool"),Oc=o(e=>(kc(e|=0),we.subarray(Fe-e,Fe)),"random"),Nc=o((e,t,r)=>{let n=(2<<31-Math.clz32(e.length-1|1))-1,i=Math.ceil(1.6*n*t/e.length);return(u=t)=>{let c="";for(;;){let l=r(i),y=i;for(;y--;)if(c+=e[l[y]&n]||"",c.length===u)return c}}},"customRandom"),Zo=o((e,t=21)=>Nc(e,t,Oc),"customAlphabet");var Rc="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",Ho=21,tT=a().check(Ie(new RegExp(`^[0-9a-zA-Z]{${Ho}}$`))),Cc=Zo(Rc,Ho);var $e=Se(Ee(e=>e instanceof Date?e.toISOString():e),a()),ue={id:a(),created:$e,updated:$e},q=o(e=>h(ot(e)),"Nullable");function Ar(e){return h(ot(j(e)))}o(Ar,"NullableEnum");var oT=Se(Ee(e=>e==="true"||e===!0?!0:e==="false"||e===!1?!1:void 0),h(H())),Lt=o(e=>Se(Ee(t=>Array.isArray(t)?t:t!==void 0?[t]:void 0),h(D(e))),"OptionalArrayFromQuery");var sT=R(a(),N());var ht=(P=>(P.OPENAI="openai",P.OPENROUTER="openrouter",P.ANTHROPIC="anthropic",P.AZURE="azure",P.GOOGLE="google",P.ACTIVEPIECES="activepieces",P.CLOUDFLARE_GATEWAY="cloudflare-gateway",P.CUSTOM="custom",P.BEDROCK="bedrock",P.MISTRAL="mistral",P))(ht||{});var xT=a().check(Ie(/^#[0-9A-Fa-f]{6}$/));var PT=p({filename:a(),data:N(),type:z("file"),mimetype:h(a())});var Dc=Ce(Wo());var AT=p({...ue,name:a(),permissions:D(a()),platformId:q(a()),type:a(),userCount:h(re())});var Go=(n=>(n.AGENT_DECIDE="agent-decide",n.CHOOSE_YOURSELF="choose-yourself",n.LEAVE_EMPTY="leave-empty",n))(Go||{}),zr=(r=>(r.FILE="FILE",r.TABLE="TABLE",r))(zr||{}),wr=(n=>(n.SSE="sse",n.STREAMABLE_HTTP="streamable-http",n.SIMPLE_HTTP="http",n))(wr||{});var kr=(n=>(n.TEXT="text",n.NUMBER="number",n.BOOLEAN="boolean",n))(kr||{});var Or=(r=>(r.IN_PROGRESS="in-progress",r.COMPLETED="completed",r))(Or||{});var Uc=p({mode:j(Go),value:N()}),Mc=p({auth:h(a()),fields:R(a(),Uc)}),jc=p({pieceName:a(),pieceVersion:a(),actionName:a(),predefinedInput:h(Mc)}),Lc=p({type:z("PIECE"),toolName:a().check(pe(1)),pieceMetadata:jc}),Fc=p({type:z("none")}),Bc=p({type:z("access_token"),accessToken:a()}),Vc=p({type:z("api_key"),apiKey:a(),apiKeyHeader:a()}),Zc=p({type:z("headers"),headers:R(a(),a())}),Hc=je("type",[Fc,Bc,Vc,Zc]),Ko=p({type:z("FLOW"),toolName:a().check(pe(1)),externalFlowId:a(),flowDisplayName:h(a())}),Jo=p({type:z("MCP"),toolName:a().check(pe(1)),serverUrl:Oo(),protocol:j(wr),auth:Hc}),Xo=p({type:z("KNOWLEDGE_BASE"),toolName:a().check(pe(1)),sourceType:j(zr),sourceId:a(),sourceName:a()}),qc=je("type",[Lc,Ko,Jo,Xo]),Wc=p({displayName:a(),description:h(a()),type:j(kr)}),Yo=p({type:z("MARKDOWN"),markdown:a()}),Be={type:z("TOOL_CALL"),input:q(R(a(),N())),output:h(N()),toolName:a(),status:j(Or),toolCallId:a(),startTime:a(),endTime:h(a())},tI=p(Be),Qo=je("toolCallType",[p({...Be,toolCallType:z("PIECE"),pieceName:a(),pieceVersion:a(),actionName:a()}),p({...Be,toolCallType:z("FLOW"),displayName:a(),externalFlowId:a()}),p({...Be,toolCallType:z("MCP"),displayName:a(),serverUrl:a()}),p({...Be,toolCallType:z("KNOWLEDGE_BASE"),displayName:a(),sourceType:a()}),p({...Be,toolCallType:z("UNKNOWN"),displayName:a()})]),Gc=U([Yo,Qo]);var Nr=(r=>(r.IMAGE="image",r.TEXT="text",r))(Nr||{}),Pe=p({apiKey:a()}),Kc=Pe,Jc=p({apiKey:a(),apiKeyHash:a()}),Xc=Pe,Yc=Pe,Qc=Pe,ep=Pe,tp=Pe,rp=Pe,np=Pe,ei=p({accessKeyId:a().check(pe(1)),secretAccessKey:a().check(pe(1))}),op=p({}),ip=p({}),ap=p({}),sp=p({}),up=p({}),cp=p({}),ti=p({modelId:a(),modelName:a(),modelType:j(Nr)}),ri=p({apiKeyHeader:a(),baseUrl:a(),models:D(ti),defaultHeaders:h(R(a(),a()))}),ni=p({accountId:a(),gatewayId:a(),models:D(ti),vertexProject:h(a()),vertexRegion:h(a())}),oi=p({resourceName:a(),apiVersion:Se(Ee(e=>typeof e=="string"&&e.trim().length===0?void 0:e),h(a()))}),ii=p({region:a().check(pe(1))}),pp=U([Kc,Qc,ep,tp,rp,Yc,Xc,Jc,ei,np]),ai=U([ri,ni,oi,ii,op,ap,sp,up,ip,cp]),lp=p({id:a(),name:a(),type:j(Nr)}),dp=p({id:a(),name:a(),provider:j(ht),config:ai,enabledForChat:H()}),mp=p({provider:j(ht),config:ai,auth:pp,platformId:a()});var iI={openai:"openai",anthropic:"anthropic","google-ai-studio":"google","google-vertex-ai":"google"};var fp=p({base64Url:a(),fileName:a(),extension:h(a())}),gp=p({mimeType:a(),url:a(),fileName:h(a())}),Rr=U([fp,gp]);var yp=U([p({type:z("file"),value:Rr}),p({type:z("markdown"),value:a(),files:h(D(Rr))})]),hp=p({sessionId:a(),message:a(),files:h(D(a()))});var ui=(r=>(r.ON_NEW_RECORD="ON_NEW_RECORD",r.ON_UPDATE_RECORD="ON_UPDATE_RECORD",r))(ui||{}),ci=(r=>(r.ENABLED="ENABLED",r.DISABLED="DISABLED",r))(ci||{}),Cr=(n=>(n.RECORD_CREATED="RECORD_CREATED",n.RECORD_UPDATED="RECORD_UPDATED",n.RECORD_DELETED="RECORD_DELETED",n))(Cr||{});var vp=U([p({...ue,name:a(),externalId:a(),type:z("STATIC_DROPDOWN"),tableId:a(),projectId:a(),data:p({options:D(p({value:a()}))})}),p({...ue,name:a(),externalId:a(),type:U([z("TEXT"),z("NUMBER"),z("DATE")]),tableId:a(),projectId:a()})]),xp=p({...ue,name:a(),folderId:q(a()),projectId:a(),externalId:a(),status:Ar(ci),trigger:Ar(ui)}),_p=p({...ue,tableId:a(),projectId:a(),cells:R(a(),p({updated:a(),created:a(),value:N(),fieldName:a()}))}),Pp=p({events:D(j(Cr)),webhookUrl:a(),flowId:a()}),bp=p({fields:D(p({id:a(),name:a()})),rows:D(R(a(),a())),name:a()}),Tp=p({projectId:a(),limit:h(it.number()),cursor:h(a()),name:h(a()),externalIds:Lt(a()),folderId:h(a()),folderIds:Lt(a())}),Ip=p({records:D(D(p({fieldId:a(),value:li()}))),tableId:a()}),Ep=p({cells:h(D(p({fieldId:a(),value:li()}))),tableId:a(),agentUpdate:h(H())}),pi=je("operator",[ke("eq"),ke("neq"),ke("gt"),ke("gte"),ke("lt"),ke("lte"),ke("co"),si("exists"),si("not_exists")]),Sp=p({tableId:a(),limit:h(it.number()),cursor:h(a()),filters:Lt(pi)});function li(){return Se(Ee(e=>e==null?e:String(e)),ot(a()))}o(li,"coerceToString");function ke(e){return p({fieldId:a(),operator:z(e),value:a()})}o(ke,"valueFilter");function si(e){return p({fieldId:a(),operator:z(e)})}o(si,"existenceFilter");var $p=p({status:h(re()),body:h(N()),headers:h(R(a(),a()))}),Ap=p({...ue,deleted:q($e),ownerId:a(),displayName:a(),platformId:a(),externalId:q(a())});var di=p({name:a(),description:h(a()),type:a(),required:H()}),zp=p({pieceName:a(),triggerName:a(),input:p({toolName:a(),toolDescription:a(),inputSchema:D(di),returnsResponse:H()})});var mi="^[0-9]+\\.[0-9]+\\.[0-9]+$",II=new RegExp(mi),kp="^([~^])?[0-9]+\\.[0-9]+\\.[0-9]+$",EI=a().check(Ie(new RegExp(mi))),SI=a().check(Ie(new RegExp(kp))),Op=p({packageType:z("ARCHIVE"),pieceType:j(Le),pieceName:a(),pieceVersion:a(),archiveId:a(),platformId:a()}),fi=p({packageType:z("REGISTRY"),pieceType:z("OFFICIAL"),pieceName:a(),pieceVersion:a()}),gi=p({packageType:z("REGISTRY"),pieceType:z("CUSTOM"),pieceName:a(),pieceVersion:a(),platformId:a()}),$I=U([fi,gi]),AI=U([Op,fi,gi]),yi=(t=>(t.CRON_EXPRESSION="CRON_EXPRESSION",t))(yi||{}),Np=p({type:j(yi),cronExpression:a(),timezone:a()}),zI=p({...ue,type:j(ee),projectId:a(),flowId:a(),triggerName:a(),schedule:q(Np),flowVersionId:a(),pieceName:a(),pieceVersion:a(),deleted:q(a()),simulate:H()}),hi=(m=>(m.UNKNOWN="UNKNOWN",m.FLOW_RUN_LOG="FLOW_RUN_LOG",m.FLOW_RUN_LOG_SLICE="FLOW_RUN_LOG_SLICE",m.PACKAGE_ARCHIVE="PACKAGE_ARCHIVE",m.FLOW_STEP_FILE="FLOW_STEP_FILE",m.SAMPLE_DATA="SAMPLE_DATA",m.TRIGGER_PAYLOAD="TRIGGER_PAYLOAD",m.SAMPLE_DATA_INPUT="SAMPLE_DATA_INPUT",m.TRIGGER_EVENT_FILE="TRIGGER_EVENT_FILE",m.PROJECT_RELEASE="PROJECT_RELEASE",m.FLOW_VERSION_BACKUP="FLOW_VERSION_BACKUP",m.PLATFORM_ASSET="PLATFORM_ASSET",m.USER_PROFILE_PICTURE="USER_PROFILE_PICTURE",m.WEBHOOK_PAYLOAD="WEBHOOK_PAYLOAD",m.KNOWLEDGE_BASE="KNOWLEDGE_BASE",m.FLOW_BUNDLE="FLOW_BUNDLE",m))(hi||{}),vi=(r=>(r.NONE="NONE",r.ZSTD="ZSTD",r))(vi||{}),xi=(r=>(r.S3="S3",r.DB="DB",r))(xi||{}),wI=p({...ue,projectId:q(a()),platformId:q(a()),type:j(hi),compression:j(vi),data:h(N()),location:j(xi),size:q(re()),fileName:q(a()),s3Key:q(a()),metadata:q(R(a(),a()))}),_i=(n=>(n.ADMIN="ADMIN",n.MEMBER="MEMBER",n.OPERATOR="OPERATOR",n))(_i||{}),Pi=(r=>(r.ACTIVE="ACTIVE",r.INACTIVE="INACTIVE",r))(Pi||{}),kI=p({id:a(),email:a(),firstName:a(),status:j(Pi),externalId:q(a()),platformId:q(a()),platformRole:j(_i),lastName:a(),created:$e,updated:$e,lastActiveDate:q($e),imageUrl:q(a())});var Dr=p({...Z.shape,...M(R(a(),N()),"OBJECT").shape});var Ei=p({...Z.shape,...M(a(),"COLOR").shape});var Ur=U([ae,he,Ut,xe,se,ve,Ir,at,Er,_e,ct,Dr,pt,ut,st,Ei]),f={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"}},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"}},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 fe=p({displayName:a(),description:h(a())});var Si=p({username:a(),password:a()}),Mr=p({...fe.shape,username:p({displayName:a(),description:h(a())}),password:p({displayName:a(),description:h(a())}),...M(Si,"BASIC_AUTH").shape});var Up=R(a(),U([ae,he,_e,xe,se])),jr=p({...fe.shape,props:Up,...M(N(),"CUSTOM_AUTH").shape});var Oe=p({...fe.shape,...M(p({auth:a()}),"SECRET_TEXT").shape});var Mp=R(a(),U([ae,he,Oe,_e,xe,se,ve,Ut])),$i=p({...fe.shape,props:Mp,...M(N(),"OIDC").shape});var Lr=(r=>(r.HEADER="HEADER",r.BODY="BODY",r))(Lr||{}),Ai=U([ae,Oe,se]),zi=R(a(),Ai),jp=p({props:h(R(a(),Ai)),authUrl:a(),tokenUrl:a(),scope:D(a()),prompt:h(U([z("none"),z("consent"),z("login"),z("omit")])),pkce:h(H()),pkceMethod:h(U([z("plain"),z("S256")])),authorizationMethod:h(j(Lr)),grantType:h(U([j(mt),z(Sr)])),extra:h(R(a(),a()))}),wi=p({access_token:a(),props:h(zi),data:R(a(),nt())}),Fr=p({...fe.shape,...jp.shape,...M(wi,"OAUTH2").shape});var Ve=U([Mr,jr,$i,Fr,Oe]),vt="Connection",Br={SecretText(e){return{...e,valueSchema:void 0,type:"SECRET_TEXT"}},OAuth2(e){return{...e,valueSchema:void 0,type:"OAUTH2",displayName:e.displayName||vt}},BasicAuth(e){return{...e,valueSchema:void 0,type:"BASIC_AUTH",displayName:e.displayName||vt,required:!0}},CustomAuth(e){return{...e,valueSchema:void 0,type:"CUSTOM_AUTH",displayName:e.displayName||vt}},OIDC(e){return{...e,valueSchema:void 0,type:"OIDC",displayName:e.displayName||vt}},None(){}};var cS={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 Lp=p({...Z.shape,...M(N(),"CUSTOM").shape,code:a()});var Fp=U([Ur,Ve]),Vr=R(a(),Fp),zS=R(a(),Ur);var ki=U([p({strategy:z("CRON"),cronExpression:a()}),p({strategy:z("NONE")})]),Ze=class{constructor(t,r,n,i,u,c,l,y,v,P,A,_,s,d,g,m,x,b,F){this.name=t;this.displayName=r;this.description=n;this.requireAuth=i;this.props=u;this.type=c;this.handshakeConfiguration=l;this.onHandshake=y;this.renewConfiguration=v;this.onRenew=P;this.onEnable=A;this.onDisable=_;this.onStart=s;this.run=d;this.test=g;this.sampleData=m;this.testStrategy=x;this.outputSchema=b;this.aiMetadata=F}static{o(this,"ITrigger")}},J=o(e=>{switch(e.type){case"WEBHOOK":return new Ze(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);case"POLLING":return new Ze(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);case"MANUAL":return new Ze(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);case"APP_WEBHOOK":return new Ze(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,le(e.sampleData)&&le(e.test)?"SIMULATION":"TEST_FUNCTION",e.outputSchema,e.aiMetadata)}},"createTrigger");var Oi="2",Bt="0.82.0";var Zr=class{constructor(t,r,n,i,u,c,l,y,v=Bt,P,A=""){this.displayName=t;this.logoUrl=r;this.authors=n;this.events=i;this.categories=l;this.auth=y;this.minimumSupportedRelease=v;this.maximumSupportedRelease=P;this.description=A;this._actions={};this._triggers={};this.getContextInfo=o(()=>({version:Oi}),"getContextInfo");(!Bp(v)||Vp(v,Bt))&&(this.minimumSupportedRelease=Bt),u.forEach(_=>this._actions[_.name]=_),c.forEach(_=>this._triggers[_.name]=_)}static{o(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:this.auth,minimumSupportedRelease:this.minimumSupportedRelease,maximumSupportedRelease:this.maximumSupportedRelease,contextInfo:this.getContextInfo?.()}}getAction(t){return this._actions[t]}getTrigger(t){return this._triggers[t]}actions(){return this._actions}triggers(){return this._triggers}},Ni=o(e=>{if(e.auth&&Array.isArray(e.auth)&&!e.auth.every((r,n,i)=>n===i.findIndex(u=>u.type===r.type)))throw new Error("Auth properties must be unique by type");return new Zr(e.displayName,e.logoUrl,e.authors??[],e.events,e.actions,e.triggers,e.categories??[],e.auth,e.minimumSupportedRelease,e.maximumSupportedRelease,e.description)},"createPiece");function Bp(e){return/^\d+\.\d+\.\d+$/.test(e)}o(Bp,"isValidSimpleSemver");function Vp(e,t){let[r,n,i]=e.split(".").map(Number),[u,c,l]=t.split(".").map(Number);return r!==u?r<u:n!==c?n<c:i<l}o(Vp,"isSemverLessThan");var Zp=h(R(a(),R(a(),a()))),Ri=p({id:h(a()),name:a(),displayName:a(),logoUrl:a(),description:a(),authors:D(a()),platformId:h(a()),directoryPath:h(a()),auth:h(U([Ve,D(Ve)])),version:a(),categories:h(D(j(dt))),minimumSupportedRelease:h(a()),maximumSupportedRelease:h(a()),i18n:Zp}),Hp=j(["human","ai","both"]),Ci=p({description:h(a()),idempotent:h(H())}),Di=p({name:a(),displayName:a(),description:a(),props:Vr,requireAuth:H(),errorHandlingOptions:h(Tr),outputSchema:h(Ct()),audience:h(Hp),aiMetadata:h(Ci)}),Ui=p({name:a(),displayName:a(),description:a(),props:Vr,errorHandlingOptions:h(Tr),type:j(ee),sampleData:N(),handshakeConfiguration:h(Ct()),renewConfiguration:h(ki),testStrategy:j(gt),outputSchema:h(Ct()),aiMetadata:h(Ci)}),qp=p({...Ri.shape,actions:R(a(),Di),triggers:R(a(),Ui)}),Wp=p({...Ri.shape,actions:re(),triggers:re(),suggestedActions:h(D(Ui)),suggestedTriggers:h(D(Di))}),Mi=p({projectUsage:re(),tags:h(D(a())),pieceType:j(Le),packageType:j(lt),platformId:h(a()),archiveId:h(a())}),z$=p({...qp.shape,...Mi.shape}),w$=p({...Wp.shape,...Mi.shape}),k$=p({name:a(),version:a()});var Gp=Ce(require("path")),Kp=Ce(require("fs/promises"));var Vt=class{constructor(t,r){this.baseUrl=t;this.authenticationConverter=r}static{o(this,"BaseHttpClient")}getUrl(t){let r=new URL(`${this.baseUrl}${t.url}`),n=`${r.origin}${r.pathname}`,i=new URLSearchParams;return r.searchParams.forEach((u,c)=>{i.append(c,u)}),{urlWithoutQueryParams:n,queryParams:i}}getHeaders(t){let r={Accept:"application/json"};if(t.authentication&&this.populateAuthentication(t.authentication,r),t.body)switch(t.headers?.["Content-Type"]){case"text/csv":r["Content-Type"]="text/csv";break;default:r["Content-Type"]="application/json";break}return t.headers&&(r={...r,...t.headers}),r}populateAuthentication(t,r){this.authenticationConverter.convert(t,r)}};var Zt=class{static{o(this,"DelegatingAuthenticationConverter")}constructor(t=new Hr,r=new qr){this.converters={BEARER_TOKEN:t,BASIC:r}}convert(t,r){return this.converters[t.type].convert(t,r)}},Hr=class{static{o(this,"BearerTokenAuthenticationConverter")}convert(t,r){return r.Authorization=`Bearer ${t.token}`,r}},qr=class{static{o(this,"BasicTokenAuthenticationConverter")}convert(t,r){let n=`${t.username}:${t.password}`,i=Buffer.from(n).toString("base64");return r.Authorization=`Basic ${i}`,r}};var Ht=class extends Error{constructor(r,n){let i=n.status||500,u=Buffer.isBuffer(n.responseBody)?n.responseBody.toString():n.responseBody;super(JSON.stringify({response:{status:i,body:u},request:{body:r}}));this.requestBody=r;this.status=i,this.responseBody=u}static{o(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}}};var qt=class extends Vt{static{o(this,"FetchHttpClient")}constructor(t="",r=new Zt){super(t,r)}async sendRequest(t,r){process.env.NODE_TLS_REJECT_UNAUTHORIZED="0";let{urlWithoutQueryParams:n,queryParams:i}=this.getUrl(t),u=this.getHeaders(t),c=t.queryParams??{};for(let[F,ie]of Object.entries(c))i.append(F,ie);let l=i.toString(),y=l?`${n}?${l}`:n,v=t.responseType??"json",P=t.followRedirects??!0,A=t.retries??0,{body:_,extraHeaders:s,isStream:d}=Jp(t.body,u),g=Yp({...u,...s}),m=await Xp(async()=>{let F=new AbortController,ie=t.timeout&&t.timeout>0?setTimeout(()=>F.abort(),t.timeout):void 0;try{let ce={method:t.method.toString(),headers:g,body:_,redirect:P?"follow":"manual",signal:F.signal};return d&&(ce.duplex="half"),r?.dispatcher!==void 0&&(ce.dispatcher=r.dispatcher),await fetch(y,ce)}finally{ie!==void 0&&clearTimeout(ie)}},A),x=P?300:400;if(m.status<200||m.status>=x){let F=await ji(m,v),ie=new Ht(t.body,{status:m.status,responseBody:F});throw console.error("[HttpClient#(sanitized error message)] Request failed:",ie),ie}let b=await ji(m,v);return{status:m.status,headers:Qp(m.headers),body:b}}};function Jp(e,t){return tl(e)?{body:void 0,extraHeaders:{},isStream:!1}:el(e)?{body:e,extraHeaders:e.getHeaders(),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}}o(Jp,"serializeBody");async function ji(e,t){switch(t){case"arraybuffer":return Buffer.from(await e.arrayBuffer());case"blob":return await e.blob();case"text":return await e.text();case"json":default:{let r=await e.text();if(r.length===0)return;try{return JSON.parse(r)}catch{return r}}}}o(ji,"parseResponseBody");async function Xp(e,t){let r;for(let n=0;n<=t;n++)try{let i=await e();if(i.status>=500&&n<t){await Li(n);continue}return i}catch(i){if(r=i,n<t){await Li(n);continue}throw i}throw r}o(Xp,"sendWithRetries");function Li(e){let t=Math.min(1e3*2**e,3e4);return new Promise(r=>setTimeout(r,t))}o(Li,"backoff");function Yp(e){let t={};for(let[r,n]of Object.entries(e))n!==void 0&&(t[r]=Array.isArray(n)?n.join(", "):n);return t}o(Yp,"normalizeHeaders");function Qp(e){let t={};return e.forEach((r,n)=>{t[n]=r}),t}o(Qp,"toHttpHeaders");function el(e){return typeof e=="object"&&e!==null&&typeof e.getHeaders=="function"&&typeof e.pipe=="function"}o(el,"isNodeFormData");function tl(e){return e==null}o(tl,"isNil");var Wt=new qt;var Gt=(c=>(c.GET="GET",c.POST="POST",c.PATCH="PATCH",c.PUT="PUT",c.DELETE="DELETE",c.HEAD="HEAD",c))(Gt||{});var Bd=Ce(require("fs")),qs=Ce(Hs());var Vd={"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 Zd(e){let t=e.split(";")[0].trim().toLowerCase();return Vd[t]??""}o(Zd,"contentTypeToExtension");var Hd=o(({baseUrl:e,relativePath:t})=>{let r=e.endsWith("/")?e:`${e}/`,n=t.startsWith("/")?t.slice(1):t;return`${r}${n}`},"joinBaseUrlWithRelativePath"),qd=o((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 Ws({auth:e,baseUrl:t,authMapping:r,description:n,displayName:i,name:u,props:c,extraProps:l,authLocation:y="headers"}){return V({audience:"human",name:u||"custom_api_call",displayName:i||"Custom API Call",description:n||"Make a custom API call to a specific endpoint",auth:e,requireAuth:!!e,props:{url:f.DynamicProperties({auth:e,displayName:"",required:!0,refreshers:[],props:o(async({auth:v})=>({url:f.ShortText({displayName:"URL",description:`You can either use the full URL or the relative path to the base URL
|
|
3
|
-
i.e ${
|
|
1
|
+
"use strict";var Du=Object.create;var Ye=Object.defineProperty;var Uu=Object.getOwnPropertyDescriptor;var Mu=Object.getOwnPropertyNames;var Lu=Object.getPrototypeOf,ju=Object.prototype.hasOwnProperty;var o=(e,t)=>Ye(e,"name",{value:t,configurable:!0});var A=(e,t)=>()=>{try{return t||e((t={exports:{}}).exports,t),t.exports}catch(r){throw t=0,r}},On=(e,t)=>{for(var r in t)Ye(e,r,{get:t[r],enumerable:!0})},kn=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of Mu(t))!ju.call(e,i)&&i!==r&&Ye(e,i,{get:()=>t[i],enumerable:!(n=Uu(t,i))||n.enumerable});return e};var Me=(e,t,r)=>(r=e!=null?Du(Lu(e)):{},kn(t||!e||!e.__esModule?Ye(r,"default",{value:e,enumerable:!0}):r,e)),Bu=e=>kn(Ye({},"__esModule",{value:!0}),e);var ri=A((ti,Ht)=>{(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"),i=new RegExp("^0x[a-f0-9]+$","i"),u="%[0-9a-z]{1,}",c="(?:[0-9a-f]+::?)+",p={zoneIndex:new RegExp(u,"i"),native:new RegExp(`^(::)?(${c})?([0-9a-f]+)?(::)?(${u})?$`,"i"),deprecatedTransitional:new RegExp(`^(?:::)(${t}\\.${t}\\.${t}\\.${t}(${u})?)$`,"i"),transitional:new RegExp(`^((?:${c})|(?:::)(?:${c})?)${t}\\.${t}\\.${t}\\.${t}(${u})?$`,"i")};function h(s,d){if(s.indexOf("::")!==s.lastIndexOf("::"))return null;let g=0,m=-1,_=(s.match(p.zoneIndex)||[])[0],b,B;for(_&&(_=_.substring(1),s=s.replace(/%.+$/,""));(m=s.indexOf(":",m+1))>=0;)g++;if(s.substr(0,2)==="::"&&g--,s.substr(-2,2)==="::"&&g--,g>d)return null;for(B=d-g,b=":";B--;)b+="0:";return s=s.replace("::",b),s[0]===":"&&(s=s.slice(1)),s[s.length-1]===":"&&(s=s.slice(0,-1)),d=(function(){let ie=s.split(":"),pe=[];for(let Xe=0;Xe<ie.length;Xe++)pe.push(parseInt(ie[Xe],16));return pe})(),{parts:d,zoneId:_}}o(h,"expandIPv6");function v(s,d,g,m){if(s.length!==d.length)throw new Error("ipaddr: cannot match CIDR for objects with different lengths");let _=0,b;for(;m>0;){if(b=g-m,b<0&&(b=0),s[_]>>b!==d[_]>>b)return!1;m-=g,_+=1}return!0}o(v,"matchCIDR");function P(s){if(i.test(s))return parseInt(s,16);if(s[0]==="0"&&!isNaN(parseInt(s[1],10))){if(n.test(s))return parseInt(s,8);throw new Error(`ipaddr: cannot parse ${s} as octal`)}return parseInt(s,10)}o(P,"parseIntAuto");function $(s,d){for(;s.length<d;)s=`0${s}`;return s}o($,"padPart");let x={};x.IPv4=(function(){function s(d){if(d.length!==4)throw new Error("ipaddr: ipv4 octet count should be 4");let g,m;for(g=0;g<d.length;g++)if(m=d[g],!(0<=m&&m<=255))throw new Error("ipaddr: ipv4 octet should fit in 8 bits");this.octets=d}return o(s,"IPv4"),s.prototype.SpecialRanges={unspecified:[[new s([0,0,0,0]),8]],broadcast:[[new s([255,255,255,255]),32]],multicast:[[new s([224,0,0,0]),4]],linkLocal:[[new s([169,254,0,0]),16]],loopback:[[new s([127,0,0,0]),8]],carrierGradeNat:[[new s([100,64,0,0]),10]],private:[[new s([10,0,0,0]),8],[new s([172,16,0,0]),12],[new s([192,168,0,0]),16]],reserved:[[new s([192,0,0,0]),24],[new s([192,0,2,0]),24],[new s([192,88,99,0]),24],[new s([198,18,0,0]),15],[new s([198,51,100,0]),24],[new s([203,0,113,0]),24],[new s([240,0,0,0]),4]],as112:[[new s([192,175,48,0]),24],[new s([192,31,196,0]),24]],amt:[[new s([192,52,193,0]),24]]},s.prototype.kind=function(){return"ipv4"},s.prototype.match=function(d,g){let m;if(g===void 0&&(m=d,d=m[0],g=m[1]),d.kind()!=="ipv4")throw new Error("ipaddr: cannot match ipv4 address with non-ipv4 one");return v(this.octets,d.octets,8,g)},s.prototype.prefixLengthFromSubnetMask=function(){let d=0,g=!1,m={0:8,128:7,192:6,224:5,240:4,248:3,252:2,254:1,255:0},_,b,B;for(_=3;_>=0;_-=1)if(b=this.octets[_],b in m){if(B=m[b],g&&B!==0)return null;B!==8&&(g=!0),d+=B}else return null;return 32-d},s.prototype.range=function(){return x.subnetMatch(this,this.SpecialRanges)},s.prototype.toByteArray=function(){return this.octets.slice(0)},s.prototype.toIPv4MappedAddress=function(){return x.IPv6.parse(`::ffff:${this.toString()}`)},s.prototype.toNormalizedString=function(){return this.toString()},s.prototype.toString=function(){return this.octets.join(".")},s})(),x.IPv4.broadcastAddressFromCIDR=function(s){try{let d=this.parseCIDR(s),g=d[0].toByteArray(),m=this.subnetMaskFromPrefixLength(d[1]).toByteArray(),_=[],b=0;for(;b<4;)_.push(parseInt(g[b],10)|parseInt(m[b],10)^255),b++;return new this(_)}catch{throw new Error("ipaddr: the address does not have IPv4 CIDR format")}},x.IPv4.isIPv4=function(s){return this.parser(s)!==null},x.IPv4.isValid=function(s){try{return new this(this.parser(s)),!0}catch{return!1}},x.IPv4.isValidCIDR=function(s){try{return this.parseCIDR(s),!0}catch{return!1}},x.IPv4.isValidFourPartDecimal=function(s){return!!(x.IPv4.isValid(s)&&s.match(/^(0|[1-9]\d*)(\.(0|[1-9]\d*)){3}$/))},x.IPv4.isValidCIDRFourPartDecimal=function(s){let d=s.match(/^(.+)\/(\d+)$/);return!x.IPv4.isValidCIDR(s)||!d?!1:x.IPv4.isValidFourPartDecimal(d[1])},x.IPv4.networkAddressFromCIDR=function(s){let d,g,m,_,b;try{for(d=this.parseCIDR(s),m=d[0].toByteArray(),b=this.subnetMaskFromPrefixLength(d[1]).toByteArray(),_=[],g=0;g<4;)_.push(parseInt(m[g],10)&parseInt(b[g],10)),g++;return new this(_)}catch{throw new Error("ipaddr: the address does not have IPv4 CIDR format")}},x.IPv4.parse=function(s){let d=this.parser(s);if(d===null)throw new Error("ipaddr: string is not formatted like an IPv4 Address");return new this(d)},x.IPv4.parseCIDR=function(s){let d;if(d=s.match(/^(.+)\/(\d+)$/)){let g=parseInt(d[2]);if(g>=0&&g<=32){let m=[this.parse(d[1]),g];return Object.defineProperty(m,"toString",{value:o(function(){return this.join("/")},"value")}),m}}throw new Error("ipaddr: string is not formatted like an IPv4 CIDR range")},x.IPv4.parser=function(s){let d,g,m;if(d=s.match(r.fourOctet))return(function(){let _=d.slice(1,6),b=[];for(let B=0;B<_.length;B++)g=_[B],b.push(P(g));return b})();if(d=s.match(r.longValue)){if(m=P(d[1]),m>4294967295||m<0)throw new Error("ipaddr: address outside defined range");return(function(){let _=[],b;for(b=0;b<=24;b+=8)_.push(m>>b&255);return _})().reverse()}else return(d=s.match(r.twoOctet))?(function(){let _=d.slice(1,4),b=[];if(m=P(_[1]),m>16777215||m<0)throw new Error("ipaddr: address outside defined range");return b.push(P(_[0])),b.push(m>>16&255),b.push(m>>8&255),b.push(m&255),b})():(d=s.match(r.threeOctet))?(function(){let _=d.slice(1,5),b=[];if(m=P(_[2]),m>65535||m<0)throw new Error("ipaddr: address outside defined range");return b.push(P(_[0])),b.push(P(_[1])),b.push(m>>8&255),b.push(m&255),b})():null},x.IPv4.subnetMaskFromPrefixLength=function(s){if(s=parseInt(s),s<0||s>32)throw new Error("ipaddr: invalid IPv4 prefix length");let d=[0,0,0,0],g=0,m=Math.floor(s/8);for(;g<m;)d[g]=255,g++;return m<4&&(d[m]=Math.pow(2,s%8)-1<<8-s%8),new this(d)},x.IPv6=(function(){function s(d,g){let m,_;if(d.length===16)for(this.parts=[],m=0;m<=14;m+=2)this.parts.push(d[m]<<8|d[m+1]);else if(d.length===8)this.parts=d;else throw new Error("ipaddr: ipv6 part count should be 8 or 16");for(m=0;m<this.parts.length;m++)if(_=this.parts[m],!(0<=_&&_<=65535))throw new Error("ipaddr: ipv6 part should fit in 16 bits");g&&(this.zoneId=g)}return o(s,"IPv6"),s.prototype.SpecialRanges={unspecified:[new s([0,0,0,0,0,0,0,0]),128],linkLocal:[new s([65152,0,0,0,0,0,0,0]),10],multicast:[new s([65280,0,0,0,0,0,0,0]),8],loopback:[new s([0,0,0,0,0,0,0,1]),128],uniqueLocal:[new s([64512,0,0,0,0,0,0,0]),7],ipv4Mapped:[new s([0,0,0,0,0,65535,0,0]),96],discard:[new s([256,0,0,0,0,0,0,0]),64],rfc6145:[new s([0,0,0,0,65535,0,0,0]),96],rfc6052:[new s([100,65435,0,0,0,0,0,0]),96],"6to4":[new s([8194,0,0,0,0,0,0,0]),16],teredo:[new s([8193,0,0,0,0,0,0,0]),32],benchmarking:[new s([8193,2,0,0,0,0,0,0]),48],amt:[new s([8193,3,0,0,0,0,0,0]),32],as112v6:[[new s([8193,4,274,0,0,0,0,0]),48],[new s([9760,79,32768,0,0,0,0,0]),48]],deprecated:[new s([8193,16,0,0,0,0,0,0]),28],orchid2:[new s([8193,32,0,0,0,0,0,0]),28],droneRemoteIdProtocolEntityTags:[new s([8193,48,0,0,0,0,0,0]),28],reserved:[[new s([8193,0,0,0,0,0,0,0]),23],[new s([8193,3512,0,0,0,0,0,0]),32]]},s.prototype.isIPv4MappedAddress=function(){return this.range()==="ipv4Mapped"},s.prototype.kind=function(){return"ipv6"},s.prototype.match=function(d,g){let m;if(g===void 0&&(m=d,d=m[0],g=m[1]),d.kind()!=="ipv6")throw new Error("ipaddr: cannot match ipv6 address with non-ipv6 one");return v(this.parts,d.parts,16,g)},s.prototype.prefixLengthFromSubnetMask=function(){let d=0,g=!1,m={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},_,b;for(let B=7;B>=0;B-=1)if(_=this.parts[B],_ in m){if(b=m[_],g&&b!==0)return null;b!==16&&(g=!0),d+=b}else return null;return 128-d},s.prototype.range=function(){return x.subnetMatch(this,this.SpecialRanges)},s.prototype.toByteArray=function(){let d,g=[],m=this.parts;for(let _=0;_<m.length;_++)d=m[_],g.push(d>>8),g.push(d&255);return g},s.prototype.toFixedLengthString=function(){let d=(function(){let m=[];for(let _=0;_<this.parts.length;_++)m.push($(this.parts[_].toString(16),4));return m}).call(this).join(":"),g="";return this.zoneId&&(g=`%${this.zoneId}`),d+g},s.prototype.toIPv4Address=function(){if(!this.isIPv4MappedAddress())throw new Error("ipaddr: trying to convert a generic ipv6 address to ipv4");let d=this.parts.slice(-2),g=d[0],m=d[1];return new x.IPv4([g>>8,g&255,m>>8,m&255])},s.prototype.toNormalizedString=function(){let d=(function(){let m=[];for(let _=0;_<this.parts.length;_++)m.push(this.parts[_].toString(16));return m}).call(this).join(":"),g="";return this.zoneId&&(g=`%${this.zoneId}`),d+g},s.prototype.toRFC5952String=function(){let d=/((^|:)(0(:|$)){2,})/g,g=this.toNormalizedString(),m=0,_=-1,b;for(;b=d.exec(g);)b[0].length>_&&(m=b.index,_=b[0].length);return _<0?g:`${g.substring(0,m)}::${g.substring(m+_)}`},s.prototype.toString=function(){return this.toRFC5952String()},s})(),x.IPv6.broadcastAddressFromCIDR=function(s){try{let d=this.parseCIDR(s),g=d[0].toByteArray(),m=this.subnetMaskFromPrefixLength(d[1]).toByteArray(),_=[],b=0;for(;b<16;)_.push(parseInt(g[b],10)|parseInt(m[b],10)^255),b++;return new this(_)}catch(d){throw new Error(`ipaddr: the address does not have IPv6 CIDR format (${d})`)}},x.IPv6.isIPv6=function(s){return this.parser(s)!==null},x.IPv6.isValid=function(s){if(typeof s=="string"&&s.indexOf(":")===-1)return!1;try{let d=this.parser(s);return new this(d.parts,d.zoneId),!0}catch{return!1}},x.IPv6.isValidCIDR=function(s){if(typeof s=="string"&&s.indexOf(":")===-1)return!1;try{return this.parseCIDR(s),!0}catch{return!1}},x.IPv6.networkAddressFromCIDR=function(s){let d,g,m,_,b;try{for(d=this.parseCIDR(s),m=d[0].toByteArray(),b=this.subnetMaskFromPrefixLength(d[1]).toByteArray(),_=[],g=0;g<16;)_.push(parseInt(m[g],10)&parseInt(b[g],10)),g++;return new this(_)}catch(B){throw new Error(`ipaddr: the address does not have IPv6 CIDR format (${B})`)}},x.IPv6.parse=function(s){let d=this.parser(s);if(d.parts===null)throw new Error("ipaddr: string is not formatted like an IPv6 Address");return new this(d.parts,d.zoneId)},x.IPv6.parseCIDR=function(s){let d,g,m;if((g=s.match(/^(.+)\/(\d+)$/))&&(d=parseInt(g[2]),d>=0&&d<=128))return m=[this.parse(g[1]),d],Object.defineProperty(m,"toString",{value:o(function(){return this.join("/")},"value")}),m;throw new Error("ipaddr: string is not formatted like an IPv6 CIDR range")},x.IPv6.parser=function(s){let d,g,m,_,b,B;if(m=s.match(p.deprecatedTransitional))return this.parser(`::ffff:${m[1]}`);if(p.native.test(s))return h(s,8);if((m=s.match(p.transitional))&&(B=m[6]||"",d=m[1],m[1].endsWith("::")||(d=d.slice(0,-1)),d=h(d+B,6),d.parts)){for(b=[parseInt(m[2]),parseInt(m[3]),parseInt(m[4]),parseInt(m[5])],g=0;g<b.length;g++)if(_=b[g],!(0<=_&&_<=255))return null;return d.parts.push(b[0]<<8|b[1]),d.parts.push(b[2]<<8|b[3]),{parts:d.parts,zoneId:d.zoneId}}return null},x.IPv6.subnetMaskFromPrefixLength=function(s){if(s=parseInt(s),s<0||s>128)throw new Error("ipaddr: invalid IPv6 prefix length");let d=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],g=0,m=Math.floor(s/8);for(;g<m;)d[g]=255,g++;return m<16&&(d[m]=Math.pow(2,s%8)-1<<8-s%8),new this(d)},x.fromByteArray=function(s){let d=s.length;if(d===4)return new x.IPv4(s);if(d===16)return new x.IPv6(s);throw new Error("ipaddr: the binary input is neither an IPv6 nor IPv4 address")},x.isValid=function(s){return x.IPv6.isValid(s)||x.IPv4.isValid(s)},x.isValidCIDR=function(s){return x.IPv6.isValidCIDR(s)||x.IPv4.isValidCIDR(s)},x.parse=function(s){if(x.IPv6.isValid(s))return x.IPv6.parse(s);if(x.IPv4.isValid(s))return x.IPv4.parse(s);throw new Error("ipaddr: the address has neither IPv6 nor IPv4 format")},x.parseCIDR=function(s){try{return x.IPv6.parseCIDR(s)}catch{try{return x.IPv4.parseCIDR(s)}catch{throw new Error("ipaddr: the address has neither IPv6 nor IPv4 CIDR format")}}},x.process=function(s){let d=this.parse(s);return d.kind()==="ipv6"&&d.isIPv4MappedAddress()?d.toIPv4Address():d},x.subnetMatch=function(s,d,g){let m,_,b,B;g==null&&(g="unicast");for(_ in d)if(Object.prototype.hasOwnProperty.call(d,_)){for(b=d[_],b[0]&&!(b[0]instanceof Array)&&(b=[b]),m=0;m<b.length;m++)if(B=b[m],s.kind()===B[0].kind()&&s.match.apply(s,B))return _}return g},typeof Ht<"u"&&Ht.exports?Ht.exports=x:e.ipaddr=x})(ti)});var na=A((xz,ra)=>{var ta=require("stream").Stream,Tl=require("util");ra.exports=de;function de(){this.source=null,this.dataSize=0,this.maxDataSize=1024*1024,this.pauseStream=!0,this._maxDataSizeExceeded=!1,this._released=!1,this._bufferedEvents=[]}o(de,"DelayedStream");Tl.inherits(de,ta);de.create=function(e,t){var r=new this;t=t||{};for(var n in t)r[n]=t[n];r.source=e;var i=e.emit;return e.emit=function(){return r._handleEmit(arguments),i.apply(e,arguments)},e.on("error",function(){}),r.pauseStream&&e.pause(),r};Object.defineProperty(de.prototype,"readable",{configurable:!0,enumerable:!0,get:o(function(){return this.source.readable},"get")});de.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)};de.prototype.resume=function(){this._released||this.release(),this.source.resume()};de.prototype.pause=function(){this.source.pause()};de.prototype.release=function(){this._released=!0,this._bufferedEvents.forEach(function(e){this.emit.apply(this,e)}.bind(this)),this._bufferedEvents=[]};de.prototype.pipe=function(){var e=ta.prototype.pipe.apply(this,arguments);return this.resume(),e};de.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)};de.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 sa=A((bz,aa)=>{var Il=require("util"),ia=require("stream").Stream,oa=na();aa.exports=X;function X(){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}o(X,"CombinedStream");Il.inherits(X,ia);X.create=function(e){var t=new this;e=e||{};for(var r in e)t[r]=e[r];return t};X.isStreamLike=function(e){return typeof e!="function"&&typeof e!="string"&&typeof e!="boolean"&&typeof e!="number"&&!Buffer.isBuffer(e)};X.prototype.append=function(e){var t=X.isStreamLike(e);if(t){if(!(e instanceof oa)){var r=oa.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};X.prototype.pipe=function(e,t){return ia.prototype.pipe.call(this,e,t),this.resume(),e};X.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}};X.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=X.isStreamLike(r);n&&(r.on("data",this._checkDataSize.bind(this)),this._handleErrors(r)),this._pipeNext(r)}.bind(this))};X.prototype._pipeNext=function(e){this._currentStream=e;var t=X.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()};X.prototype._handleErrors=function(e){var t=this;e.on("error",function(r){t._emitError(r)})};X.prototype.write=function(e){this.emit("data",e)};X.prototype.pause=function(){this.pauseStreams&&(this.pauseStreams&&this._currentStream&&typeof this._currentStream.pause=="function"&&this._currentStream.pause(),this.emit("pause"))};X.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")};X.prototype.end=function(){this._reset(),this.emit("end")};X.prototype.destroy=function(){this._reset(),this.emit("close")};X.prototype._reset=function(){this.writable=!1,this._streams=[],this._currentStream=null};X.prototype._checkDataSize=function(){if(this._updateDataSize(),!(this.dataSize<=this.maxDataSize)){var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(new Error(e))}};X.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)};X.prototype._emitError=function(e){this._reset(),this.emit("error",e)}});var ca=A((Iz,ua)=>{"use strict";ua.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 da=A(ne=>{"use strict";var Yt=ca(),El=require("path").extname,pa=/^\s*([^;\s]*)(?:;|\s|$)/,Sl=/^text\//i;ne.charset=la;ne.charsets={lookup:la};ne.contentType=Al;ne.extension=$l;ne.extensions=Object.create(null);ne.lookup=zl;ne.types=Object.create(null);wl(ne.extensions,ne.types);function la(e){if(!e||typeof e!="string")return!1;var t=pa.exec(e),r=t&&Yt[t[1].toLowerCase()];return r&&r.charset?r.charset:t&&Sl.test(t[1])?"UTF-8":!1}o(la,"charset");function Al(e){if(!e||typeof e!="string")return!1;var t=e.indexOf("/")===-1?ne.lookup(e):e;if(!t)return!1;if(t.indexOf("charset")===-1){var r=ne.charset(t);r&&(t+="; charset="+r.toLowerCase())}return t}o(Al,"contentType");function $l(e){if(!e||typeof e!="string")return!1;var t=pa.exec(e),r=t&&ne.extensions[t[1].toLowerCase()];return!r||!r.length?!1:r[0]}o($l,"extension");function zl(e){if(!e||typeof e!="string")return!1;var t=El("x."+e).toLowerCase().substr(1);return t&&ne.types[t]||!1}o(zl,"lookup");function wl(e,t){var r=["nginx","apache",void 0,"iana"];Object.keys(Yt).forEach(o(function(i){var u=Yt[i],c=u.extensions;if(!(!c||!c.length)){e[i]=c;for(var p=0;p<c.length;p++){var h=c[p];if(t[h]){var v=r.indexOf(Yt[t[h]].source),P=r.indexOf(u.source);if(t[h]!=="application/octet-stream"&&(v>P||v===P&&t[h].substr(0,12)==="application/"))continue}t[h]=i}}},"forEachMimeType"))}o(wl,"populateMaps")});var fa=A((Az,ma)=>{ma.exports=Ol;function Ol(e){var t=typeof setImmediate=="function"?setImmediate:typeof process=="object"&&typeof process.nextTick=="function"?process.nextTick:null;t?t(e):setTimeout(e,0)}o(Ol,"defer")});var Jr=A((zz,ya)=>{var ga=fa();ya.exports=kl;function kl(e){var t=!1;return ga(function(){t=!0}),o(function(n,i){t?e(n,i):ga(o(function(){e(n,i)},"nextTick_callback"))},"async_callback")}o(kl,"async")});var Xr=A((Oz,ha)=>{ha.exports=Rl;function Rl(e){Object.keys(e.jobs).forEach(Nl.bind(e)),e.jobs={}}o(Rl,"abort");function Nl(e){typeof this.jobs[e]=="function"&&this.jobs[e]()}o(Nl,"clean")});var Yr=A((Rz,_a)=>{var va=Jr(),Cl=Xr();_a.exports=Dl;function Dl(e,t,r,n){var i=r.keyedList?r.keyedList[r.index]:r.index;r.jobs[i]=Ul(t,i,e[i],function(u,c){i in r.jobs&&(delete r.jobs[i],u?Cl(r):r.results[i]=c,n(u,r.results))})}o(Dl,"iterate");function Ul(e,t,r,n){var i;return e.length==2?i=e(r,va(n)):i=e(r,t,va(n)),i}o(Ul,"runJob")});var Qr=A((Cz,xa)=>{xa.exports=Ml;function Ml(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(i,u){return t(e[i],e[u])}),n}o(Ml,"state")});var en=A((Uz,Pa)=>{var Ll=Xr(),jl=Jr();Pa.exports=Bl;function Bl(e){Object.keys(this.jobs).length&&(this.index=this.size,Ll(this),jl(e)(null,this.results))}o(Bl,"terminator")});var Ta=A((Lz,ba)=>{var Fl=Yr(),Vl=Qr(),Zl=en();ba.exports=Hl;function Hl(e,t,r){for(var n=Vl(e);n.index<(n.keyedList||e).length;)Fl(e,t,n,function(i,u){if(i){r(i,u);return}if(Object.keys(n.jobs).length===0){r(null,n.results);return}}),n.index++;return Zl.bind(n,r)}o(Hl,"parallel")});var tn=A((Bz,Qt)=>{var Ia=Yr(),ql=Qr(),Gl=en();Qt.exports=Wl;Qt.exports.ascending=Ea;Qt.exports.descending=Kl;function Wl(e,t,r,n){var i=ql(e,r);return Ia(e,t,i,o(function u(c,p){if(c){n(c,p);return}if(i.index++,i.index<(i.keyedList||e).length){Ia(e,t,i,u);return}n(null,i.results)},"iteratorHandler")),Gl.bind(i,n)}o(Wl,"serialOrdered");function Ea(e,t){return e<t?-1:e>t?1:0}o(Ea,"ascending");function Kl(e,t){return-1*Ea(e,t)}o(Kl,"descending")});var Aa=A((Vz,Sa)=>{var Jl=tn();Sa.exports=Xl;function Xl(e,t,r){return Jl(e,t,null,r)}o(Xl,"serial")});var za=A((Hz,$a)=>{$a.exports={parallel:Ta(),serial:Aa(),serialOrdered:tn()}});var rn=A((qz,wa)=>{"use strict";wa.exports=Object});var ka=A((Gz,Oa)=>{"use strict";Oa.exports=Error});var Na=A((Wz,Ra)=>{"use strict";Ra.exports=EvalError});var Da=A((Kz,Ca)=>{"use strict";Ca.exports=RangeError});var Ma=A((Jz,Ua)=>{"use strict";Ua.exports=ReferenceError});var ja=A((Xz,La)=>{"use strict";La.exports=SyntaxError});var er=A((Yz,Ba)=>{"use strict";Ba.exports=TypeError});var Va=A((Qz,Fa)=>{"use strict";Fa.exports=URIError});var Ha=A((ew,Za)=>{"use strict";Za.exports=Math.abs});var Ga=A((tw,qa)=>{"use strict";qa.exports=Math.floor});var Ka=A((rw,Wa)=>{"use strict";Wa.exports=Math.max});var Xa=A((nw,Ja)=>{"use strict";Ja.exports=Math.min});var Qa=A((ow,Ya)=>{"use strict";Ya.exports=Math.pow});var ts=A((iw,es)=>{"use strict";es.exports=Math.round});var ns=A((aw,rs)=>{"use strict";rs.exports=Number.isNaN||o(function(t){return t!==t},"isNaN")});var is=A((uw,os)=>{"use strict";var Yl=ns();os.exports=o(function(t){return Yl(t)||t===0?t:t<0?-1:1},"sign")});var ss=A((pw,as)=>{"use strict";as.exports=Object.getOwnPropertyDescriptor});var nn=A((lw,us)=>{"use strict";var tr=ss();if(tr)try{tr([],"length")}catch{tr=null}us.exports=tr});var ps=A((dw,cs)=>{"use strict";var rr=Object.defineProperty||!1;if(rr)try{rr({},"a",{value:1})}catch{rr=!1}cs.exports=rr});var on=A((mw,ls)=>{"use strict";ls.exports=o(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 i=42;t[r]=i;for(var u 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 c=Object.getOwnPropertySymbols(t);if(c.length!==1||c[0]!==r||!Object.prototype.propertyIsEnumerable.call(t,r))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var p=Object.getOwnPropertyDescriptor(t,r);if(p.value!==i||p.enumerable!==!0)return!1}return!0},"hasSymbols")});var fs=A((gw,ms)=>{"use strict";var ds=typeof Symbol<"u"&&Symbol,Ql=on();ms.exports=o(function(){return typeof ds!="function"||typeof Symbol!="function"||typeof ds("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:Ql()},"hasNativeSymbols")});var an=A((hw,gs)=>{"use strict";gs.exports=typeof Reflect<"u"&&Reflect.getPrototypeOf||null});var sn=A((vw,ys)=>{"use strict";var ed=rn();ys.exports=ed.getPrototypeOf||null});var _s=A((_w,vs)=>{"use strict";var td="Function.prototype.bind called on incompatible ",rd=Object.prototype.toString,nd=Math.max,od="[object Function]",hs=o(function(t,r){for(var n=[],i=0;i<t.length;i+=1)n[i]=t[i];for(var u=0;u<r.length;u+=1)n[u+t.length]=r[u];return n},"concatty"),id=o(function(t,r){for(var n=[],i=r||0,u=0;i<t.length;i+=1,u+=1)n[u]=t[i];return n},"slicy"),ad=o(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");vs.exports=o(function(t){var r=this;if(typeof r!="function"||rd.apply(r)!==od)throw new TypeError(td+r);for(var n=id(arguments,1),i,u=o(function(){if(this instanceof i){var P=r.apply(this,hs(n,arguments));return Object(P)===P?P:this}return r.apply(t,hs(n,arguments))},"binder"),c=nd(0,r.length-n.length),p=[],h=0;h<c;h++)p[h]="$"+h;if(i=Function("binder","return function ("+ad(p,",")+"){ return binder.apply(this,arguments); }")(u),r.prototype){var v=o(function(){},"Empty");v.prototype=r.prototype,i.prototype=new v,v.prototype=null}return i},"bind")});var qe=A((Pw,xs)=>{"use strict";var sd=_s();xs.exports=Function.prototype.bind||sd});var nr=A((bw,Ps)=>{"use strict";Ps.exports=Function.prototype.call});var un=A((Tw,bs)=>{"use strict";bs.exports=Function.prototype.apply});var Is=A((Iw,Ts)=>{"use strict";Ts.exports=typeof Reflect<"u"&&Reflect&&Reflect.apply});var Ss=A((Ew,Es)=>{"use strict";var ud=qe(),cd=un(),pd=nr(),ld=Is();Es.exports=ld||ud.call(pd,cd)});var $s=A((Sw,As)=>{"use strict";var dd=qe(),md=er(),fd=nr(),gd=Ss();As.exports=o(function(t){if(t.length<1||typeof t[0]!="function")throw new md("a function is required");return gd(dd,fd,t)},"callBindBasic")});var Ns=A(($w,Rs)=>{"use strict";var yd=$s(),zs=nn(),Os;try{Os=[].__proto__===Array.prototype}catch(e){if(!e||typeof e!="object"||!("code"in e)||e.code!=="ERR_PROTO_ACCESS")throw e}var cn=!!Os&&zs&&zs(Object.prototype,"__proto__"),ks=Object,ws=ks.getPrototypeOf;Rs.exports=cn&&typeof cn.get=="function"?yd([cn.get]):typeof ws=="function"?o(function(t){return ws(t==null?t:ks(t))},"getDunder"):!1});var Ls=A((ww,Ms)=>{"use strict";var Cs=an(),Ds=sn(),Us=Ns();Ms.exports=Cs?o(function(t){return Cs(t)},"getProto"):Ds?o(function(t){if(!t||typeof t!="object"&&typeof t!="function")throw new TypeError("getProto: not an object");return Ds(t)},"getProto"):Us?o(function(t){return Us(t)},"getProto"):null});var pn=A((kw,js)=>{"use strict";var hd=Function.prototype.call,vd=Object.prototype.hasOwnProperty,_d=qe();js.exports=_d.call(hd,vd)});var Gs=A((Rw,qs)=>{"use strict";var j,xd=rn(),Pd=ka(),bd=Na(),Td=Da(),Id=Ma(),Je=ja(),Ke=er(),Ed=Va(),Sd=Ha(),Ad=Ga(),$d=Ka(),zd=Xa(),wd=Qa(),Od=ts(),kd=is(),Zs=Function,ln=o(function(e){try{return Zs('"use strict"; return ('+e+").constructor;")()}catch{}},"getEvalledConstructor"),Pt=nn(),Rd=ps(),dn=o(function(){throw new Ke},"throwTypeError"),Nd=Pt?(function(){try{return arguments.callee,dn}catch{try{return Pt(arguments,"callee").get}catch{return dn}}})():dn,Ge=fs()(),te=Ls(),Cd=sn(),Dd=an(),Hs=un(),bt=nr(),We={},Ud=typeof Uint8Array>"u"||!te?j:te(Uint8Array),De={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?j:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?j:ArrayBuffer,"%ArrayIteratorPrototype%":Ge&&te?te([][Symbol.iterator]()):j,"%AsyncFromSyncIteratorPrototype%":j,"%AsyncFunction%":We,"%AsyncGenerator%":We,"%AsyncGeneratorFunction%":We,"%AsyncIteratorPrototype%":We,"%Atomics%":typeof Atomics>"u"?j:Atomics,"%BigInt%":typeof BigInt>"u"?j:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?j:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?j:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?j:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Pd,"%eval%":eval,"%EvalError%":bd,"%Float16Array%":typeof Float16Array>"u"?j:Float16Array,"%Float32Array%":typeof Float32Array>"u"?j:Float32Array,"%Float64Array%":typeof Float64Array>"u"?j:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?j:FinalizationRegistry,"%Function%":Zs,"%GeneratorFunction%":We,"%Int8Array%":typeof Int8Array>"u"?j:Int8Array,"%Int16Array%":typeof Int16Array>"u"?j:Int16Array,"%Int32Array%":typeof Int32Array>"u"?j:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":Ge&&te?te(te([][Symbol.iterator]())):j,"%JSON%":typeof JSON=="object"?JSON:j,"%Map%":typeof Map>"u"?j:Map,"%MapIteratorPrototype%":typeof Map>"u"||!Ge||!te?j:te(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":xd,"%Object.getOwnPropertyDescriptor%":Pt,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?j:Promise,"%Proxy%":typeof Proxy>"u"?j:Proxy,"%RangeError%":Td,"%ReferenceError%":Id,"%Reflect%":typeof Reflect>"u"?j:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?j:Set,"%SetIteratorPrototype%":typeof Set>"u"||!Ge||!te?j:te(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?j:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":Ge&&te?te(""[Symbol.iterator]()):j,"%Symbol%":Ge?Symbol:j,"%SyntaxError%":Je,"%ThrowTypeError%":Nd,"%TypedArray%":Ud,"%TypeError%":Ke,"%Uint8Array%":typeof Uint8Array>"u"?j:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?j:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?j:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?j:Uint32Array,"%URIError%":Ed,"%WeakMap%":typeof WeakMap>"u"?j:WeakMap,"%WeakRef%":typeof WeakRef>"u"?j:WeakRef,"%WeakSet%":typeof WeakSet>"u"?j:WeakSet,"%Function.prototype.call%":bt,"%Function.prototype.apply%":Hs,"%Object.defineProperty%":Rd,"%Object.getPrototypeOf%":Cd,"%Math.abs%":Sd,"%Math.floor%":Ad,"%Math.max%":$d,"%Math.min%":zd,"%Math.pow%":wd,"%Math.round%":Od,"%Math.sign%":kd,"%Reflect.getPrototypeOf%":Dd};if(te)try{null.error}catch(e){Bs=te(te(e)),De["%Error.prototype%"]=Bs}var Bs,Md=o(function e(t){var r;if(t==="%AsyncFunction%")r=ln("async function () {}");else if(t==="%GeneratorFunction%")r=ln("function* () {}");else if(t==="%AsyncGeneratorFunction%")r=ln("async function* () {}");else if(t==="%AsyncGenerator%"){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if(t==="%AsyncIteratorPrototype%"){var i=e("%AsyncGenerator%");i&&te&&(r=te(i.prototype))}return De[t]=r,r},"doEval"),Fs={__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"]},Tt=qe(),or=pn(),Ld=Tt.call(bt,Array.prototype.concat),jd=Tt.call(Hs,Array.prototype.splice),Vs=Tt.call(bt,String.prototype.replace),ir=Tt.call(bt,String.prototype.slice),Bd=Tt.call(bt,RegExp.prototype.exec),Fd=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,Vd=/\\(\\)?/g,Zd=o(function(t){var r=ir(t,0,1),n=ir(t,-1);if(r==="%"&&n!=="%")throw new Je("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&r!=="%")throw new Je("invalid intrinsic syntax, expected opening `%`");var i=[];return Vs(t,Fd,function(u,c,p,h){i[i.length]=p?Vs(h,Vd,"$1"):c||u}),i},"stringToPath"),Hd=o(function(t,r){var n=t,i;if(or(Fs,n)&&(i=Fs[n],n="%"+i[0]+"%"),or(De,n)){var u=De[n];if(u===We&&(u=Md(n)),typeof u>"u"&&!r)throw new Ke("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:i,name:n,value:u}}throw new Je("intrinsic "+t+" does not exist!")},"getBaseIntrinsic");qs.exports=o(function(t,r){if(typeof t!="string"||t.length===0)throw new Ke("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof r!="boolean")throw new Ke('"allowMissing" argument must be a boolean');if(Bd(/^%?[^%]*%?$/,t)===null)throw new Je("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=Zd(t),i=n.length>0?n[0]:"",u=Hd("%"+i+"%",r),c=u.name,p=u.value,h=!1,v=u.alias;v&&(i=v[0],jd(n,Ld([0,1],v)));for(var P=1,$=!0;P<n.length;P+=1){var x=n[P],s=ir(x,0,1),d=ir(x,-1);if((s==='"'||s==="'"||s==="`"||d==='"'||d==="'"||d==="`")&&s!==d)throw new Je("property names with quotes must have matching quotes");if((x==="constructor"||!$)&&(h=!0),i+="."+x,c="%"+i+"%",or(De,c))p=De[c];else if(p!=null){if(!(x in p)){if(!r)throw new Ke("base intrinsic for "+t+" exists, but the property is not available.");return}if(Pt&&P+1>=n.length){var g=Pt(p,x);$=!!g,$&&"get"in g&&!("originalValue"in g.get)?p=g.get:p=p[x]}else $=or(p,x),p=p[x];$&&!h&&(De[c]=p)}}return p},"GetIntrinsic")});var Ks=A((Cw,Ws)=>{"use strict";var qd=on();Ws.exports=o(function(){return qd()&&!!Symbol.toStringTag},"hasToStringTagShams")});var Ys=A((Uw,Xs)=>{"use strict";var Gd=Gs(),Js=Gd("%Object.defineProperty%",!0),Wd=Ks()(),Kd=pn(),Jd=er(),ar=Wd?Symbol.toStringTag:null;Xs.exports=o(function(t,r){var n=arguments.length>2&&!!arguments[2]&&arguments[2].force,i=arguments.length>2&&!!arguments[2]&&arguments[2].nonConfigurable;if(typeof n<"u"&&typeof n!="boolean"||typeof i<"u"&&typeof i!="boolean")throw new Jd("if provided, the `overrideIfSet` and `nonConfigurable` options must be booleans");ar&&(n||!Kd(t,ar))&&(Js?Js(t,ar,{configurable:!i,enumerable:!1,value:r,writable:!1}):t[ar]=r)},"setToStringTag")});var eu=A((Lw,Qs)=>{"use strict";var Xd=Function.prototype.call,Yd=Object.prototype.hasOwnProperty,Qd=qe();Qs.exports=Qd.call(Xd,Yd)});var ru=A((jw,tu)=>{"use strict";tu.exports=function(e,t){return Object.keys(t).forEach(function(r){e[r]=e[r]||t[r]}),e}});var iu=A((Bw,ou)=>{"use strict";var yn=sa(),em=require("util"),mn=require("path"),tm=require("http"),rm=require("https"),nm=require("url").parse,om=require("fs"),im=require("stream").Stream,am=require("crypto"),fn=da(),sm=za(),um=Ys(),ke=eu(),gn=ru();function nu(e){return String(e).replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/"/g,"%22")}o(nu,"escapeHeaderParam");function F(e){if(!(this instanceof F))return new F(e);this._overheadLength=0,this._valueLength=0,this._valuesToMeasure=[],yn.call(this),e=e||{};for(var t in e)this[t]=e[t]}o(F,"FormData");em.inherits(F,yn);F.LINE_BREAK=`\r
|
|
2
|
+
`;F.DEFAULT_CONTENT_TYPE="application/octet-stream";F.prototype.append=function(e,t,r){r=r||{},typeof r=="string"&&(r={filename:r});var n=yn.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 i=this._multiPartHeader(e,t,r),u=this._multiPartFooter();n(i),n(t),n(u),this._trackLength(i,t,r)};F.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)+F.LINE_BREAK.length,!(!t||!t.path&&!(t.readable&&ke(t,"httpVersion"))&&!(t instanceof im))&&(r.knownLength||this._valuesToMeasure.push(t))};F.prototype._lengthRetriever=function(e,t){ke(e,"fd")?e.end!=null&&e.end!=1/0&&e.start!=null?t(null,e.end+1-(e.start?e.start:0)):om.stat(e.path,function(r,n){if(r){t(r);return}var i=n.size-(e.start?e.start:0);t(null,i)}):ke(e,"httpVersion")?t(null,Number(e.headers["content-length"])):ke(e,"httpModule")?(e.on("response",function(r){e.pause(),t(null,Number(r.headers["content-length"]))}),e.resume()):t("Unknown stream")};F.prototype._multiPartHeader=function(e,t,r){if(typeof r.header=="string")return r.header;var n=this._getContentDisposition(t,r),i=this._getContentType(t,r),u="",c={"Content-Disposition":["form-data",'name="'+nu(e)+'"'].concat(n||[]),"Content-Type":[].concat(i||[])};typeof r.header=="object"&&gn(c,r.header);var p;for(var h in c)if(ke(c,h)){if(p=c[h],p==null)continue;Array.isArray(p)||(p=[p]),p.length&&(u+=h+": "+p.join("; ")+F.LINE_BREAK)}return"--"+this.getBoundary()+F.LINE_BREAK+u+F.LINE_BREAK};F.prototype._getContentDisposition=function(e,t){var r;if(typeof t.filepath=="string"?r=mn.normalize(t.filepath).replace(/\\/g,"/"):t.filename||e&&(e.name||e.path)?r=mn.basename(t.filename||e&&(e.name||e.path)):e&&e.readable&&ke(e,"httpVersion")&&(r=mn.basename(e.client._httpMessage.path||"")),r)return'filename="'+nu(r)+'"'};F.prototype._getContentType=function(e,t){var r=t.contentType;return!r&&e&&e.name&&(r=fn.lookup(e.name)),!r&&e&&e.path&&(r=fn.lookup(e.path)),!r&&e&&e.readable&&ke(e,"httpVersion")&&(r=e.headers["content-type"]),!r&&(t.filepath||t.filename)&&(r=fn.lookup(t.filepath||t.filename)),!r&&e&&typeof e=="object"&&(r=F.DEFAULT_CONTENT_TYPE),r};F.prototype._multiPartFooter=function(){return function(e){var t=F.LINE_BREAK,r=this._streams.length===0;r&&(t+=this._lastBoundary()),e(t)}.bind(this)};F.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+F.LINE_BREAK};F.prototype.getHeaders=function(e){var t,r={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(t in e)ke(e,t)&&(r[t.toLowerCase()]=e[t]);return r};F.prototype.setBoundary=function(e){if(typeof e!="string")throw new TypeError("FormData boundary must be a string");this._boundary=e};F.prototype.getBoundary=function(){return this._boundary||this._generateBoundary(),this._boundary};F.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(F.LINE_BREAK)])));return Buffer.concat([e,Buffer.from(this._lastBoundary())])};F.prototype._generateBoundary=function(){this._boundary="--------------------------"+am.randomBytes(12).toString("hex")};F.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};F.prototype.hasKnownLength=function(){var e=!0;return this._valuesToMeasure.length&&(e=!1),e};F.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}sm.parallel(this._valuesToMeasure,this._lengthRetriever,function(r,n){if(r){e(r);return}n.forEach(function(i){t+=i}),e(null,t)})};F.prototype.submit=function(e,t){var r,n,i={method:"post"};return typeof e=="string"?(e=nm(e),n=gn({port:e.port,path:e.pathname,host:e.hostname,protocol:e.protocol},i)):(n=gn(e,i),n.port||(n.port=n.protocol==="https:"?443:80)),n.headers=this.getHeaders(e.headers),n.protocol==="https:"?r=rm.request(n):r=tm.request(n),this.getLength(function(u,c){if(u&&u!=="Unknown stream"){this._error(u);return}if(c&&r.setHeader("Content-Length",c),this.pipe(r),t){var p,h=o(function(v,P){return r.removeListener("error",h),r.removeListener("response",p),t.call(this,v,P)},"callback");p=h.bind(this,null),r.on("error",h),r.on("response",p)}}.bind(this)),r};F.prototype._error=function(e){this.error||(this.error=e,this.pause(),this.emit("error",e))};F.prototype.toString=function(){return"[object FormData]"};um(F.prototype,"FormData");ou.exports=F});var Lm={};On(Lm,{bigcommerce:()=>Mm});module.exports=Bu(Lm);var Fu=Object.freeze({status:"aborted"});function I(e,t,r){function n(p,h){if(p._zod||Object.defineProperty(p,"_zod",{value:{def:h,constr:c,traits:new Set},enumerable:!1}),p._zod.traits.has(e))return;p._zod.traits.add(e),t(p,h);let v=c.prototype,P=Object.keys(v);for(let $=0;$<P.length;$++){let x=P[$];x in p||(p[x]=v[x].bind(p))}}o(n,"init");let i=r?.Parent??Object;class u extends i{static{o(this,"Definition")}}Object.defineProperty(u,"name",{value:e});function c(p){var h;let v=r?.Parent?new u:this;n(v,p),(h=v._zod).deferred??(h.deferred=[]);for(let P of v._zod.deferred)P();return v}return o(c,"_"),Object.defineProperty(c,"init",{value:n}),Object.defineProperty(c,Symbol.hasInstance,{value:o(p=>r?.Parent&&p instanceof r.Parent?!0:p?._zod?.traits?.has(e),"value")}),Object.defineProperty(c,"name",{value:e}),c}o(I,"$constructor");var me=class extends Error{static{o(this,"$ZodAsyncError")}constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}},Et=class extends Error{static{o(this,"$ZodEncodeError")}constructor(t){super(`Encountered unidirectional transform during encode: ${t}`),this.name="ZodEncodeError"}},lr={};function he(e){return e&&Object.assign(lr,e),lr}o(he,"config");function mr(e){let t=Object.values(e).filter(n=>typeof n=="number");return Object.entries(e).filter(([n,i])=>t.indexOf(+n)===-1).map(([n,i])=>i)}o(mr,"getEnumValues");function Nn(e,t){return typeof t=="bigint"?t.toString():t}o(Nn,"jsonStringifyReplacer");function At(e){return{get value(){{let r=e();return Object.defineProperty(this,"value",{value:r}),r}throw new Error("cached value already set")}}}o(At,"cached");function Cn(e){return e==null}o(Cn,"nullish");function $t(e){let t=e.startsWith("^")?1:0,r=e.endsWith("$")?e.length-1:e.length;return e.slice(t,r)}o($t,"cleanRegex");var Rn=Symbol("evaluating");function Y(e,t,r){let n;Object.defineProperty(e,t,{get(){if(n!==Rn)return n===void 0&&(n=Rn,n=r()),n},set(i){Object.defineProperty(e,t,{value:i})},configurable:!0})}o(Y,"defineLazy");var fr="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function Qe(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}o(Qe,"isObject");var Vu=At(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{let e=Function;return new e(""),!0}catch{return!1}});function Dn(e){if(Qe(e)===!1)return!1;let t=e.constructor;if(t===void 0||typeof t!="function")return!0;let r=t.prototype;return!(Qe(r)===!1||Object.prototype.hasOwnProperty.call(r,"isPrototypeOf")===!1)}o(Dn,"isPlainObject");var Un=new Set(["string","number","symbol"]);function Le(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}o(Le,"escapeRegex");function zt(e,t,r){let n=new e._zod.constr(t??e._zod.def);return(!t||r?.parent)&&(n._zod.parent=e),n}o(zt,"clone");function q(e){let t=e;if(!t)return{};if(typeof t=="string")return{error:o(()=>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:o(()=>t.error,"error")}:t}o(q,"normalizeParams");function Mn(e){return Object.keys(e).filter(t=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}o(Mn,"optionalKeys");var Ln={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 je(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}o(je,"aborted");function Ie(e,t){return t.map(r=>{var n;return(n=r).path??(n.path=[]),r.path.unshift(e),r})}o(Ie,"prefixIssues");function St(e){return typeof e=="string"?e:e?.message}o(St,"unwrapMessage");function Ee(e,t,r){let n={...e,path:e.path??[]};if(!e.message){let i=St(e.inst?._zod.def?.error?.(e))??St(t?.error?.(e))??St(r.customError?.(e))??St(r.localeError?.(e))??"Invalid input";n.message=i}return delete n.inst,delete n.continue,t?.reportInput||delete n.input,n}o(Ee,"finalizeIssue");function jn(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}o(jn,"getLengthableOrigin");function gr(...e){let[t,r,n]=e;return typeof t=="string"?{message:t,code:"custom",input:r,inst:n}:{...t}}o(gr,"issue");var Bn=o((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,Nn,2),Object.defineProperty(e,"toString",{value:o(()=>e.message,"value"),enumerable:!1})},"initializer"),Fn=I("$ZodError",Bn),et=I("$ZodError",Bn,{Parent:Error});var Hu=o(e=>(t,r,n,i)=>{let u=n?Object.assign(n,{async:!1}):{async:!1},c=t._zod.run({value:r,issues:[]},u);if(c instanceof Promise)throw new me;if(c.issues.length){let p=new(i?.Err??e)(c.issues.map(h=>Ee(h,u,he())));throw fr(p,i?.callee),p}return c.value},"_parse"),wt=Hu(et),qu=o(e=>async(t,r,n,i)=>{let u=n?Object.assign(n,{async:!0}):{async:!0},c=t._zod.run({value:r,issues:[]},u);if(c instanceof Promise&&(c=await c),c.issues.length){let p=new(i?.Err??e)(c.issues.map(h=>Ee(h,u,he())));throw fr(p,i?.callee),p}return c.value},"_parseAsync"),Ot=qu(et),Gu=o(e=>(t,r,n)=>{let i=n?{...n,async:!1}:{async:!1},u=t._zod.run({value:r,issues:[]},i);if(u instanceof Promise)throw new me;return u.issues.length?{success:!1,error:new(e??Fn)(u.issues.map(c=>Ee(c,i,he())))}:{success:!0,data:u.value}},"_safeParse"),tt=Gu(et),Wu=o(e=>async(t,r,n)=>{let i=n?Object.assign(n,{async:!0}):{async:!0},u=t._zod.run({value:r,issues:[]},i);return u instanceof Promise&&(u=await u),u.issues.length?{success:!1,error:new e(u.issues.map(c=>Ee(c,i,he())))}:{success:!0,data:u.value}},"_safeParseAsync"),rt=Wu(et);var Ku="(?:(?:\\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])))",Ju=new RegExp(`^${Ku}$`);var Vn=o(e=>{let t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)},"string"),Zn=/^-?\d+n?$/,Hn=/^-?\d+$/,yr=/^-?\d+(?:\.\d+)?$/,qn=/^(?:true|false)$/i;var Se=I("$ZodCheck",(e,t)=>{var r;e._zod??(e._zod={}),e._zod.def=t,(r=e._zod).onattach??(r.onattach=[])}),Xu={number:"number",bigint:"bigint",object:"date"};var Gn=I("$ZodCheckGreaterThan",(e,t)=>{Se.init(e,t);let r=Xu[typeof t.value];e._zod.onattach.push(n=>{let i=n._zod.bag,u=(t.inclusive?i.minimum:i.exclusiveMinimum)??Number.NEGATIVE_INFINITY;t.value>u&&(t.inclusive?i.minimum=t.value:i.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 Wn=I("$ZodCheckNumberFormat",(e,t)=>{Se.init(e,t),t.format=t.format||"float64";let r=t.format?.includes("int"),n=r?"int":"number",[i,u]=Ln[t.format];e._zod.onattach.push(c=>{let p=c._zod.bag;p.format=t.format,p.minimum=i,p.maximum=u,r&&(p.pattern=Hn)}),e._zod.check=c=>{let p=c.value;if(r){if(!Number.isInteger(p)){c.issues.push({expected:n,format:t.format,code:"invalid_type",continue:!1,input:p,inst:e});return}if(!Number.isSafeInteger(p)){p>0?c.issues.push({input:p,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}):c.issues.push({input:p,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}}p<i&&c.issues.push({origin:"number",input:p,code:"too_small",minimum:i,inclusive:!0,inst:e,continue:!t.abort}),p>u&&c.issues.push({origin:"number",input:p,code:"too_big",maximum:u,inclusive:!0,inst:e,continue:!t.abort})}});var Kn=I("$ZodCheckMinLength",(e,t)=>{var r;Se.init(e,t),(r=e._zod.def).when??(r.when=n=>{let i=n.value;return!Cn(i)&&i.length!==void 0}),e._zod.onattach.push(n=>{let i=n._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>i&&(n._zod.bag.minimum=t.minimum)}),e._zod.check=n=>{let i=n.value;if(i.length>=t.minimum)return;let c=jn(i);n.issues.push({origin:c,code:"too_small",minimum:t.minimum,inclusive:!0,input:i,inst:e,continue:!t.abort})}});var hr=I("$ZodCheckStringFormat",(e,t)=>{var r,n;Se.init(e,t),e._zod.onattach.push(i=>{let u=i._zod.bag;u.format=t.format,t.pattern&&(u.patterns??(u.patterns=new Set),u.patterns.add(t.pattern))}),t.pattern?(r=e._zod).check??(r.check=i=>{t.pattern.lastIndex=0,!t.pattern.test(i.value)&&i.issues.push({origin:"string",code:"invalid_format",format:t.format,input:i.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(n=e._zod).check??(n.check=()=>{})}),Jn=I("$ZodCheckRegex",(e,t)=>{hr.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 Yn={major:4,minor:3,patch:6};var W=I("$ZodType",(e,t)=>{var r;e??(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=Yn;let n=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&n.unshift(e);for(let i of n)for(let u of i._zod.onattach)u(e);if(n.length===0)(r=e._zod).deferred??(r.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{let i=o((c,p,h)=>{let v=je(c),P;for(let $ of p){if($._zod.def.when){if(!$._zod.def.when(c))continue}else if(v)continue;let x=c.issues.length,s=$._zod.check(c);if(s instanceof Promise&&h?.async===!1)throw new me;if(P||s instanceof Promise)P=(P??Promise.resolve()).then(async()=>{await s,c.issues.length!==x&&(v||(v=je(c,x)))});else{if(c.issues.length===x)continue;v||(v=je(c,x))}}return P?P.then(()=>c):c},"runChecks"),u=o((c,p,h)=>{if(je(c))return c.aborted=!0,c;let v=i(p,n,h);if(v instanceof Promise){if(h.async===!1)throw new me;return v.then(P=>e._zod.parse(P,h))}return e._zod.parse(v,h)},"handleCanaryResult");e._zod.run=(c,p)=>{if(p.skipChecks)return e._zod.parse(c,p);if(p.direction==="backward"){let v=e._zod.parse({value:c.value,issues:[]},{...p,skipChecks:!0});return v instanceof Promise?v.then(P=>u(P,c,p)):u(v,c,p)}let h=e._zod.parse(c,p);if(h instanceof Promise){if(p.async===!1)throw new me;return h.then(v=>i(v,n,p))}return i(h,n,p)}}Y(e,"~standard",()=>({validate:o(i=>{try{let u=tt(e,i);return u.success?{value:u.data}:{issues:u.error?.issues}}catch{return rt(e,i).then(c=>c.success?{value:c.data}:{issues:c.error?.issues})}},"validate"),vendor:"zod",version:1}))}),Nt=I("$ZodString",(e,t)=>{W.init(e,t),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??Vn(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}}),vr=I("$ZodStringFormat",(e,t)=>{hr.init(e,t),Nt.init(e,t)});var no=I("$ZodURL",(e,t)=>{vr.init(e,t),e._zod.check=r=>{try{let n=r.value.trim(),i=new URL(n);t.hostname&&(t.hostname.lastIndex=0,t.hostname.test(i.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(i.protocol.endsWith(":")?i.protocol.slice(0,-1):i.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=i.href:r.value=n;return}catch{r.issues.push({code:"invalid_format",format:"url",input:r.value,inst:e,continue:!t.abort})}}});var _r=I("$ZodNumber",(e,t)=>{W.init(e,t),e._zod.pattern=e._zod.bag.pattern??yr,e._zod.parse=(r,n)=>{if(t.coerce)try{r.value=Number(r.value)}catch{}let i=r.value;if(typeof i=="number"&&!Number.isNaN(i)&&Number.isFinite(i))return r;let u=typeof i=="number"?Number.isNaN(i)?"NaN":Number.isFinite(i)?void 0:"Infinity":void 0;return r.issues.push({expected:"number",code:"invalid_type",input:i,inst:e,...u?{received:u}:{}}),r}}),oo=I("$ZodNumberFormat",(e,t)=>{Wn.init(e,t),_r.init(e,t)}),xr=I("$ZodBoolean",(e,t)=>{W.init(e,t),e._zod.pattern=qn,e._zod.parse=(r,n)=>{if(t.coerce)try{r.value=!!r.value}catch{}let i=r.value;return typeof i=="boolean"||r.issues.push({expected:"boolean",code:"invalid_type",input:i,inst:e}),r}}),io=I("$ZodBigInt",(e,t)=>{W.init(e,t),e._zod.pattern=Zn,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 ao=I("$ZodAny",(e,t)=>{W.init(e,t),e._zod.parse=r=>r}),so=I("$ZodUnknown",(e,t)=>{W.init(e,t),e._zod.parse=r=>r});var uo=I("$ZodVoid",(e,t)=>{W.init(e,t),e._zod.parse=(r,n)=>{let i=r.value;return typeof i>"u"||r.issues.push({expected:"void",code:"invalid_type",input:i,inst:e}),r}}),co=I("$ZodDate",(e,t)=>{W.init(e,t),e._zod.parse=(r,n)=>{if(t.coerce)try{r.value=new Date(r.value)}catch{}let i=r.value,u=i instanceof Date;return u&&!Number.isNaN(i.getTime())||r.issues.push({expected:"date",code:"invalid_type",input:i,...u?{received:"Invalid Date"}:{},inst:e}),r}});function Qn(e,t,r){e.issues.length&&t.issues.push(...Ie(r,e.issues)),t.value[r]=e.value}o(Qn,"handleArrayResult");var po=I("$ZodArray",(e,t)=>{W.init(e,t),e._zod.parse=(r,n)=>{let i=r.value;if(!Array.isArray(i))return r.issues.push({expected:"array",code:"invalid_type",input:i,inst:e}),r;r.value=Array(i.length);let u=[];for(let c=0;c<i.length;c++){let p=i[c],h=t.element._zod.run({value:p,issues:[]},n);h instanceof Promise?u.push(h.then(v=>Qn(v,r,c))):Qn(h,r,c)}return u.length?Promise.all(u).then(()=>r):r}});function Rt(e,t,r,n,i){if(e.issues.length){if(i&&!(r in n))return;t.issues.push(...Ie(r,e.issues))}e.value===void 0?r in n&&(t.value[r]=void 0):t.value[r]=e.value}o(Rt,"handlePropertyResult");function Yu(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=Mn(e.shape);return{...e,keys:t,keySet:new Set(t),numKeys:t.length,optionalKeys:new Set(r)}}o(Yu,"normalizeDef");function Qu(e,t,r,n,i,u){let c=[],p=i.keySet,h=i.catchall._zod,v=h.def.type,P=h.optout==="optional";for(let $ in t){if(p.has($))continue;if(v==="never"){c.push($);continue}let x=h.run({value:t[$],issues:[]},n);x instanceof Promise?e.push(x.then(s=>Rt(s,r,$,t,P))):Rt(x,r,$,t,P)}return c.length&&r.issues.push({code:"unrecognized_keys",keys:c,input:t,inst:u}),e.length?Promise.all(e).then(()=>r):r}o(Qu,"handleCatchall");var lo=I("$ZodObject",(e,t)=>{if(W.init(e,t),!Object.getOwnPropertyDescriptor(t,"shape")?.get){let p=t.shape;Object.defineProperty(t,"shape",{get:o(()=>{let h={...p};return Object.defineProperty(t,"shape",{value:h}),h},"get")})}let n=At(()=>Yu(t));Y(e._zod,"propValues",()=>{let p=t.shape,h={};for(let v in p){let P=p[v]._zod;if(P.values){h[v]??(h[v]=new Set);for(let $ of P.values)h[v].add($)}}return h});let i=Qe,u=t.catchall,c;e._zod.parse=(p,h)=>{c??(c=n.value);let v=p.value;if(!i(v))return p.issues.push({expected:"object",code:"invalid_type",input:v,inst:e}),p;p.value={};let P=[],$=c.shape;for(let x of c.keys){let s=$[x],d=s._zod.optout==="optional",g=s._zod.run({value:v[x],issues:[]},h);g instanceof Promise?P.push(g.then(m=>Rt(m,p,x,v,d))):Rt(g,p,x,v,d)}return u?Qu(P,v,p,h,n.value,e):P.length?Promise.all(P).then(()=>p):p}});function eo(e,t,r,n){for(let u of e)if(u.issues.length===0)return t.value=u.value,t;let i=e.filter(u=>!je(u));return i.length===1?(t.value=i[0].value,i[0]):(t.issues.push({code:"invalid_union",input:t.value,inst:r,errors:e.map(u=>u.issues.map(c=>Ee(c,n,he())))}),t)}o(eo,"handleUnionResults");var Pr=I("$ZodUnion",(e,t)=>{W.init(e,t),Y(e._zod,"optin",()=>t.options.some(i=>i._zod.optin==="optional")?"optional":void 0),Y(e._zod,"optout",()=>t.options.some(i=>i._zod.optout==="optional")?"optional":void 0),Y(e._zod,"values",()=>{if(t.options.every(i=>i._zod.values))return new Set(t.options.flatMap(i=>Array.from(i._zod.values)))}),Y(e._zod,"pattern",()=>{if(t.options.every(i=>i._zod.pattern)){let i=t.options.map(u=>u._zod.pattern);return new RegExp(`^(${i.map(u=>$t(u.source)).join("|")})$`)}});let r=t.options.length===1,n=t.options[0]._zod.run;e._zod.parse=(i,u)=>{if(r)return n(i,u);let c=!1,p=[];for(let h of t.options){let v=h._zod.run({value:i.value,issues:[]},u);if(v instanceof Promise)p.push(v),c=!0;else{if(v.issues.length===0)return v;p.push(v)}}return c?Promise.all(p).then(h=>eo(h,i,e,u)):eo(p,i,e,u)}});var mo=I("$ZodDiscriminatedUnion",(e,t)=>{t.inclusive=!1,Pr.init(e,t);let r=e._zod.parse;Y(e._zod,"propValues",()=>{let i={};for(let u of t.options){let c=u._zod.propValues;if(!c||Object.keys(c).length===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(u)}"`);for(let[p,h]of Object.entries(c)){i[p]||(i[p]=new Set);for(let v of h)i[p].add(v)}}return i});let n=At(()=>{let i=t.options,u=new Map;for(let c of i){let p=c._zod.propValues?.[t.discriminator];if(!p||p.size===0)throw new Error(`Invalid discriminated union option at index "${t.options.indexOf(c)}"`);for(let h of p){if(u.has(h))throw new Error(`Duplicate discriminator value "${String(h)}"`);u.set(h,c)}}return u});e._zod.parse=(i,u)=>{let c=i.value;if(!Qe(c))return i.issues.push({code:"invalid_type",expected:"object",input:c,inst:e}),i;let p=n.value.get(c?.[t.discriminator]);return p?p._zod.run(i,u):t.unionFallback?r(i,u):(i.issues.push({code:"invalid_union",errors:[],note:"No matching discriminator",discriminator:t.discriminator,input:c,path:[t.discriminator],inst:e}),i)}});var fo=I("$ZodRecord",(e,t)=>{W.init(e,t),e._zod.parse=(r,n)=>{let i=r.value;if(!Dn(i))return r.issues.push({expected:"record",code:"invalid_type",input:i,inst:e}),r;let u=[],c=t.keyType._zod.values;if(c){r.value={};let p=new Set;for(let v of c)if(typeof v=="string"||typeof v=="number"||typeof v=="symbol"){p.add(typeof v=="number"?v.toString():v);let P=t.valueType._zod.run({value:i[v],issues:[]},n);P instanceof Promise?u.push(P.then($=>{$.issues.length&&r.issues.push(...Ie(v,$.issues)),r.value[v]=$.value})):(P.issues.length&&r.issues.push(...Ie(v,P.issues)),r.value[v]=P.value)}let h;for(let v in i)p.has(v)||(h=h??[],h.push(v));h&&h.length>0&&r.issues.push({code:"unrecognized_keys",input:i,inst:e,keys:h})}else{r.value={};for(let p of Reflect.ownKeys(i)){if(p==="__proto__")continue;let h=t.keyType._zod.run({value:p,issues:[]},n);if(h instanceof Promise)throw new Error("Async schemas not supported in object keys currently");if(typeof p=="string"&&yr.test(p)&&h.issues.length){let $=t.keyType._zod.run({value:Number(p),issues:[]},n);if($ instanceof Promise)throw new Error("Async schemas not supported in object keys currently");$.issues.length===0&&(h=$)}if(h.issues.length){t.mode==="loose"?r.value[p]=i[p]:r.issues.push({code:"invalid_key",origin:"record",issues:h.issues.map($=>Ee($,n,he())),input:p,path:[p],inst:e});continue}let P=t.valueType._zod.run({value:i[p],issues:[]},n);P instanceof Promise?u.push(P.then($=>{$.issues.length&&r.issues.push(...Ie(p,$.issues)),r.value[h.value]=$.value})):(P.issues.length&&r.issues.push(...Ie(p,P.issues)),r.value[h.value]=P.value)}}return u.length?Promise.all(u).then(()=>r):r}});var go=I("$ZodEnum",(e,t)=>{W.init(e,t);let r=mr(t.entries),n=new Set(r);e._zod.values=n,e._zod.pattern=new RegExp(`^(${r.filter(i=>Un.has(typeof i)).map(i=>typeof i=="string"?Le(i):i.toString()).join("|")})$`),e._zod.parse=(i,u)=>{let c=i.value;return n.has(c)||i.issues.push({code:"invalid_value",values:r,input:c,inst:e}),i}}),yo=I("$ZodLiteral",(e,t)=>{if(W.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"?Le(n):n?Le(n.toString()):String(n)).join("|")})$`),e._zod.parse=(n,i)=>{let u=n.value;return r.has(u)||n.issues.push({code:"invalid_value",values:t.values,input:u,inst:e}),n}});var ho=I("$ZodTransform",(e,t)=>{W.init(e,t),e._zod.parse=(r,n)=>{if(n.direction==="backward")throw new Et(e.constructor.name);let i=t.transform(r.value,r);if(n.async)return(i instanceof Promise?i:Promise.resolve(i)).then(c=>(r.value=c,r));if(i instanceof Promise)throw new me;return r.value=i,r}});function to(e,t){return e.issues.length&&t===void 0?{issues:[],value:void 0}:e}o(to,"handleOptionalResult");var vo=I("$ZodOptional",(e,t)=>{W.init(e,t),e._zod.optin="optional",e._zod.optout="optional",Y(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,void 0]):void 0),Y(e._zod,"pattern",()=>{let r=t.innerType._zod.pattern;return r?new RegExp(`^(${$t(r.source)})?$`):void 0}),e._zod.parse=(r,n)=>{if(t.innerType._zod.optin==="optional"){let i=t.innerType._zod.run(r,n);return i instanceof Promise?i.then(u=>to(u,r.value)):to(i,r.value)}return r.value===void 0?r:t.innerType._zod.run(r,n)}});var _o=I("$ZodNullable",(e,t)=>{W.init(e,t),Y(e._zod,"optin",()=>t.innerType._zod.optin),Y(e._zod,"optout",()=>t.innerType._zod.optout),Y(e._zod,"pattern",()=>{let r=t.innerType._zod.pattern;return r?new RegExp(`^(${$t(r.source)}|null)$`):void 0}),Y(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 xo=I("$ZodPipe",(e,t)=>{W.init(e,t),Y(e._zod,"values",()=>t.in._zod.values),Y(e._zod,"optin",()=>t.in._zod.optin),Y(e._zod,"optout",()=>t.out._zod.optout),Y(e._zod,"propValues",()=>t.in._zod.propValues),e._zod.parse=(r,n)=>{if(n.direction==="backward"){let u=t.out._zod.run(r,n);return u instanceof Promise?u.then(c=>kt(c,t.in,n)):kt(u,t.in,n)}let i=t.in._zod.run(r,n);return i instanceof Promise?i.then(u=>kt(u,t.out,n)):kt(i,t.out,n)}});function kt(e,t,r){return e.issues.length?(e.aborted=!0,e):t._zod.run({value:e.value,issues:e.issues},r)}o(kt,"handlePipeResult");var Po=I("$ZodCustom",(e,t)=>{Se.init(e,t),W.init(e,t),e._zod.parse=(r,n)=>r,e._zod.check=r=>{let n=r.value,i=t.fn(n);if(i instanceof Promise)return i.then(u=>ro(u,r,n,e));ro(i,r,n,e)}});function ro(e,t,r,n){if(!e){let i={code:"custom",input:r,inst:n,path:[...n._zod.def.path??[]],continue:!n._zod.def.abort};n._zod.def.params&&(i.params=n._zod.def.params),t.issues.push(gr(i))}}o(ro,"handleRefineResult");var To;var br=class{static{o(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 i={...n,...this._map.get(t)};return Object.keys(i).length?i:void 0}return this._map.get(t)}has(t){return this._map.has(t)}};function Io(){return new br}o(Io,"registry");(To=globalThis).__zod_globalRegistry??(To.__zod_globalRegistry=Io());var Tr=globalThis.__zod_globalRegistry;function Eo(e,t){return new e({type:"string",...q(t)})}o(Eo,"_string");function So(e,t){return new e({type:"string",coerce:!0,...q(t)})}o(So,"_coercedString");function Ao(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...q(t)})}o(Ao,"_url");function $o(e,t){return new e({type:"number",checks:[],...q(t)})}o($o,"_number");function zo(e,t){return new e({type:"number",coerce:!0,checks:[],...q(t)})}o(zo,"_coercedNumber");function wo(e,t){return new e({type:"number",check:"number_format",abort:!1,format:"safeint",...q(t)})}o(wo,"_int");function Oo(e,t){return new e({type:"boolean",...q(t)})}o(Oo,"_boolean");function ko(e,t){return new e({type:"boolean",coerce:!0,...q(t)})}o(ko,"_coercedBoolean");function Ro(e,t){return new e({type:"bigint",coerce:!0,...q(t)})}o(Ro,"_coercedBigint");function No(e){return new e({type:"any"})}o(No,"_any");function Co(e){return new e({type:"unknown"})}o(Co,"_unknown");function Do(e,t){return new e({type:"void",...q(t)})}o(Do,"_void");function Uo(e,t){return new e({type:"date",coerce:!0,...q(t)})}o(Uo,"_coercedDate");function Ct(e,t){return new Gn({check:"greater_than",...q(t),value:e,inclusive:!0})}o(Ct,"_gte");function le(e,t){return new Kn({check:"min_length",...q(t),minimum:e})}o(le,"_minLength");function Ae(e,t){return new Jn({check:"string_format",format:"regex",...q(t),pattern:e})}o(Ae,"_regex");function Mo(e,t,r){let n=q(r);return n.abort??(n.abort=!0),new e({type:"custom",check:"custom",fn:t,...n})}o(Mo,"_custom");var Q=I("ZodMiniType",(e,t)=>{if(!e._zod)throw new Error("Uninitialized schema in ZodMiniType.");W.init(e,t),e.def=t,e.type=t.type,e.parse=(r,n)=>wt(e,r,n,{callee:e.parse}),e.safeParse=(r,n)=>tt(e,r,n),e.parseAsync=async(r,n)=>Ot(e,r,n,{callee:e.parseAsync}),e.safeParseAsync=async(r,n)=>rt(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)=>zt(e,r,n),e.brand=()=>e,e.register=((r,n)=>(r.add(e,n),e)),e.apply=r=>r(e)}),Ut=I("ZodMiniString",(e,t)=>{Nt.init(e,t),Q.init(e,t)});function a(e){return Eo(Ut,e)}o(a,"string");var Lo=I("ZodMiniStringFormat",(e,t)=>{vr.init(e,t),Ut.init(e,t)});var dc=I("ZodMiniURL",(e,t)=>{no.init(e,t),Lo.init(e,t)});function jo(e){return Ao(dc,e)}o(jo,"url");var Mt=I("ZodMiniNumber",(e,t)=>{_r.init(e,t),Q.init(e,t)});function re(e){return $o(Mt,e)}o(re,"number");var mc=I("ZodMiniNumberFormat",(e,t)=>{oo.init(e,t),Mt.init(e,t)});function Bo(e){return wo(mc,e)}o(Bo,"int");var Ir=I("ZodMiniBoolean",(e,t)=>{xr.init(e,t),Q.init(e,t)});function H(e){return Oo(Ir,e)}o(H,"boolean");var Fo=I("ZodMiniBigInt",(e,t)=>{io.init(e,t),Q.init(e,t)});var fc=I("ZodMiniAny",(e,t)=>{ao.init(e,t),Q.init(e,t)});function ot(){return No(fc)}o(ot,"any");var gc=I("ZodMiniUnknown",(e,t)=>{so.init(e,t),Q.init(e,t)});function R(){return Co(gc)}o(R,"unknown");var yc=I("ZodMiniVoid",(e,t)=>{uo.init(e,t),Q.init(e,t)});function Vo(e){return Do(yc,e)}o(Vo,"_void");var Zo=I("ZodMiniDate",(e,t)=>{co.init(e,t),Q.init(e,t)});var hc=I("ZodMiniArray",(e,t)=>{po.init(e,t),Q.init(e,t)});function D(e,t){return new hc({type:"array",element:e,...q(t)})}o(D,"array");var vc=I("ZodMiniObject",(e,t)=>{lo.init(e,t),Q.init(e,t),Y(e,"shape",()=>t.shape)});function l(e,t){let r={type:"object",shape:e??{},...q(t)};return new vc(r)}o(l,"object");var _c=I("ZodMiniUnion",(e,t)=>{Pr.init(e,t),Q.init(e,t)});function U(e,t){return new _c({type:"union",options:e,...q(t)})}o(U,"union");var xc=I("ZodMiniDiscriminatedUnion",(e,t)=>{mo.init(e,t),Q.init(e,t)});function $e(e,t,r){return new xc({type:"union",options:t,discriminator:e,...q(r)})}o($e,"discriminatedUnion");var Pc=I("ZodMiniRecord",(e,t)=>{fo.init(e,t),Q.init(e,t)});function N(e,t,r){return new Pc({type:"record",keyType:e,valueType:t,...q(r)})}o(N,"record");var bc=I("ZodMiniEnum",(e,t)=>{go.init(e,t),Q.init(e,t),e.options=Object.values(t.entries)});function L(e,t){let r=Array.isArray(e)?Object.fromEntries(e.map(n=>[n,n])):e;return new bc({type:"enum",entries:r,...q(t)})}o(L,"_enum");var Tc=I("ZodMiniLiteral",(e,t)=>{yo.init(e,t),Q.init(e,t)});function z(e,t){return new Tc({type:"literal",values:Array.isArray(e)?e:[e],...q(t)})}o(z,"literal");var Ic=I("ZodMiniTransform",(e,t)=>{ho.init(e,t),Q.init(e,t)});function ze(e){return new Ic({type:"transform",transform:e})}o(ze,"transform");var Ec=I("ZodMiniOptional",(e,t)=>{vo.init(e,t),Q.init(e,t)});function y(e){return new Ec({type:"optional",innerType:e})}o(y,"optional");var Sc=I("ZodMiniNullable",(e,t)=>{_o.init(e,t),Q.init(e,t)});function it(e){return new Sc({type:"nullable",innerType:e})}o(it,"nullable");var Ac=I("ZodMiniPipe",(e,t)=>{xo.init(e,t),Q.init(e,t)});function we(e,t){return new Ac({type:"pipe",in:e,out:t})}o(we,"pipe");var $c=I("ZodMiniCustom",(e,t)=>{Po.init(e,t),Q.init(e,t)});function Lt(e,t){return Mo($c,e??(()=>!0),t)}o(Lt,"custom");var at={};On(at,{bigint:()=>Nc,boolean:()=>Rc,date:()=>Cc,number:()=>kc,string:()=>Oc});function Oc(e){return So(Ut,e)}o(Oc,"string");function kc(e){return zo(Mt,e)}o(kc,"number");function Rc(e){return ko(Ir,e)}o(Rc,"boolean");function Nc(e){return Ro(Fo,e)}o(Nc,"bigint");function Cc(e){return Uo(Zo,e)}o(Cc,"date");var Sr=l({retryOnFailure:l({defaultValue:y(H()),hide:y(H())}),continueOnFailure:l({defaultValue:y(H()),hide:y(H())})}),Er=class{constructor(t,r,n,i,u,c,p,h,v,P,$){this.name=t;this.displayName=r;this.description=n;this.props=i;this.run=u;this.test=c;this.requireAuth=p;this.errorHandlingOptions=h;this.outputSchema=v;this.audience=P;this.aiMetadata=$}static{o(this,"IAction")}},V=o(e=>new Er(e.name,e.displayName,e.description,e.props,e.run,e.test??e.run,e.requireAuth??!0,e.errorHandlingOptions??{continueOnFailure:{defaultValue:!1},retryOnFailure:{defaultValue:!1}},e.outputSchema,e.audience,e.aiMetadata),"createAction");var Z=l({displayName:a(),description:y(a())}),M=o((e,t)=>l({type:z(t),required:H(),defaultValue:y(ot())}),"TPropertyValue");var ae=l({...Z.shape,...M(a(),"SHORT_TEXT").shape}),ve=l({...Z.shape,...M(a(),"LONG_TEXT").shape});var qo=l({label:a(),value:R()}),jt=l({disabled:y(H()),placeholder:y(a()),options:D(qo)});var se=l({...Z.shape,options:jt,...M(R(),"STATIC_DROPDOWN").shape}),_e=l({...Z.shape,options:jt,...M(D(R()),"STATIC_MULTI_SELECT_DROPDOWN").shape});var Ar=l({...Z.shape,...M(R(),"DROPDOWN").shape,refreshers:D(a())}),st=l({...Z.shape,...M(D(R()),"MULTI_SELECT_DROPDOWN").shape,refreshers:D(a())});var xe=l({...Z.shape,...M(H(),"CHECKBOX").shape});var Pe=l({...Z.shape,...M(re(),"NUMBER").shape});var ut=l({...Z.shape,streaming:y(H()),...M(R(),"FILE").shape});var ct=l({...Z.shape,...M(a(),"DATE_TIME").shape});var Go=N(a(),U([ae,ve,se,st,_e,xe,Pe,ut,ct])),pt=l({...Z.shape,properties:Go,...M(D(R()),"ARRAY").shape});var lt=l({...Z.shape,...M(U([N(a(),R())]),"JSON").shape});var Wo=U([ae,se,lt,pt,_e]),Uc=N(a(),Wo),$r=l({refreshers:D(a()),...Z.shape,...M(R(),"DYNAMIC").shape});var Bt=l({...Z.shape,...M(Vo(),"MARKDOWN").shape});var dt=(r=>(r.ARCHIVE="ARCHIVE",r.REGISTRY="REGISTRY",r))(dt||{}),Be=(r=>(r.CUSTOM="CUSTOM",r.OFFICIAL="OFFICIAL",r))(Be||{}),mt=(_=>(_.ARTIFICIAL_INTELLIGENCE="ARTIFICIAL_INTELLIGENCE",_.COMMUNICATION="COMMUNICATION",_.COMMERCE="COMMERCE",_.CORE="CORE",_.UNIVERSAL_AI="UNIVERSAL_AI",_.FLOW_CONTROL="FLOW_CONTROL",_.BUSINESS_INTELLIGENCE="BUSINESS_INTELLIGENCE",_.ACCOUNTING="ACCOUNTING",_.PRODUCTIVITY="PRODUCTIVITY",_.CONTENT_AND_FILES="CONTENT_AND_FILES",_.DEVELOPER_TOOLS="DEVELOPER_TOOLS",_.CUSTOMER_SUPPORT="CUSTOMER_SUPPORT",_.FORMS_AND_SURVEYS="FORMS_AND_SURVEYS",_.HUMAN_RESOURCES="HUMAN_RESOURCES",_.PAYMENT_PROCESSING="PAYMENT_PROCESSING",_.MARKETING="MARKETING",_.SALES_AND_CRM="SALES_AND_CRM",_))(mt||{});var ft=(r=>(r.AUTHORIZATION_CODE="authorization_code",r.CLIENT_CREDENTIALS="client_credentials",r))(ft||{}),zr="both_client_credentials_and_authorization_code";var ee=(i=>(i.POLLING="POLLING",i.WEBHOOK="WEBHOOK",i.APP_WEBHOOK="APP_WEBHOOK",i.MANUAL="MANUAL",i))(ee||{}),gt=(u=>(u.NONE="NONE",u.HEADER_PRESENT="HEADER_PRESENT",u.QUERY_PRESENT="QUERY_PRESENT",u.BODY_PARAM_PRESENT="BODY_PARAM_PRESENT",u.HEAD_REQUEST="HEAD_REQUEST",u))(gt||{}),Mc=l({strategy:L(gt),paramName:y(a())}),yt=(r=>(r.SIMULATION="SIMULATION",r.TEST_FUNCTION="TEST_FUNCTION",r))(yt||{});var Ft=(r=>(r.WEBSOCKET="WEBSOCKET",r.NONE="NONE",r))(Ft||{}),Ko=l({status:y(re()),body:y(R()),headers:y(N(a(),a()))}),Jo=l({type:z("DELAY"),resumeDateTime:a(),requestIdToReply:y(a()),handlerId:y(a()),streamStepProgress:y(L(Ft))}),Xo=l({type:z("WEBHOOK"),requestId:a(),requestIdToReply:y(a()),response:Ko,handlerId:y(a()),streamStepProgress:y(L(Ft))}),Lc=U([Jo,Xo]);var jc=l({body:R(),rawBody:y(R()),headers:N(a(),a()),queryParams:N(a(),a())});function ue(e){return e==null}o(ue,"isNil");function ht(e){return e==null?!0:typeof e=="string"||Array.isArray(e)?e.length===0:typeof e=="object"?Object.keys(e).length===0:!1}o(ht,"isEmpty");function Vt(e,t){if(e==null)throw new Error(`${t} is null or undefined`)}o(Vt,"assertNotNullOrUndefined");var wr=Me(require("crypto"),1);var Bc=128,Re,Fe,Fc=o(e=>{!Re||Re.length<e?(Re=Buffer.allocUnsafe(e*Bc),wr.default.randomFillSync(Re),Fe=0):Fe+e>Re.length&&(wr.default.randomFillSync(Re),Fe=0),Fe+=e},"fillPool"),Vc=o(e=>(Fc(e|=0),Re.subarray(Fe-e,Fe)),"random"),Zc=o((e,t,r)=>{let n=(2<<31-Math.clz32(e.length-1|1))-1,i=Math.ceil(1.6*n*t/e.length);return(u=t)=>{let c="";for(;;){let p=r(i),h=i;for(;h--;)if(c+=e[p[h]&n]||"",c.length===u)return c}}},"customRandom"),Qo=o((e,t=21)=>Zc(e,t,Vc),"customAlphabet");var Hc="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",ei=21,xT=a().check(Ae(new RegExp(`^[0-9a-zA-Z]{${ei}}$`))),qc=Qo(Hc,ei);var Oe=we(ze(e=>e instanceof Date?e.toISOString():e),a()),ce={id:a(),created:Oe,updated:Oe},G=o(e=>y(it(e)),"Nullable");function Or(e){return y(it(L(e)))}o(Or,"NullableEnum");var TT=we(ze(e=>e==="true"||e===!0?!0:e==="false"||e===!1?!1:void 0),y(H())),Zt=o(e=>we(ze(t=>Array.isArray(t)?t:t!==void 0?[t]:void 0),y(D(e))),"OptionalArrayFromQuery");var ST=N(a(),R());var vt=(P=>(P.OPENAI="openai",P.OPENROUTER="openrouter",P.ANTHROPIC="anthropic",P.AZURE="azure",P.GOOGLE="google",P.ACTIVEPIECES="activepieces",P.CLOUDFLARE_GATEWAY="cloudflare-gateway",P.CUSTOM="custom",P.BEDROCK="bedrock",P.MISTRAL="mistral",P))(vt||{});var MT=a().check(Ae(/^#[0-9A-Fa-f]{6}$/));var jT=l({filename:a(),data:R(),type:z("file"),mimetype:y(a())});var Gc=Me(ri());var GT=l({...ce,name:a(),permissions:D(a()),platformId:G(a()),type:a(),userCount:y(re())});var ni=(n=>(n.AGENT_DECIDE="agent-decide",n.CHOOSE_YOURSELF="choose-yourself",n.LEAVE_EMPTY="leave-empty",n))(ni||{}),kr=(r=>(r.FILE="FILE",r.TABLE="TABLE",r))(kr||{}),Rr=(n=>(n.SSE="sse",n.STREAMABLE_HTTP="streamable-http",n.SIMPLE_HTTP="http",n))(Rr||{});var Nr=(n=>(n.TEXT="text",n.NUMBER="number",n.BOOLEAN="boolean",n))(Nr||{});var Cr=(r=>(r.IN_PROGRESS="in-progress",r.COMPLETED="completed",r))(Cr||{});var Wc=l({mode:L(ni),value:R()}),Kc=l({auth:y(a()),fields:N(a(),Wc)}),Jc=l({pieceName:a(),pieceVersion:a(),actionName:a(),predefinedInput:y(Kc)}),Xc=l({type:z("PIECE"),toolName:a().check(le(1)),pieceMetadata:Jc}),Yc=l({type:z("none")}),Qc=l({type:z("access_token"),accessToken:a()}),ep=l({type:z("api_key"),apiKey:a(),apiKeyHeader:a()}),tp=l({type:z("headers"),headers:N(a(),a())}),rp=$e("type",[Yc,Qc,ep,tp]),oi=l({type:z("FLOW"),toolName:a().check(le(1)),externalFlowId:a(),flowDisplayName:y(a())}),ii=l({type:z("MCP"),toolName:a().check(le(1)),serverUrl:jo(),protocol:L(Rr),auth:rp}),ai=l({type:z("KNOWLEDGE_BASE"),toolName:a().check(le(1)),sourceType:L(kr),sourceId:a(),sourceName:a()}),np=$e("type",[Xc,oi,ii,ai]),op=l({displayName:a(),description:y(a()),type:L(Nr)}),si=l({type:z("MARKDOWN"),markdown:a()}),Ve={type:z("TOOL_CALL"),input:G(N(a(),R())),output:y(R()),toolName:a(),status:L(Cr),toolCallId:a(),startTime:a(),endTime:y(a())},II=l(Ve),ui=$e("toolCallType",[l({...Ve,toolCallType:z("PIECE"),pieceName:a(),pieceVersion:a(),actionName:a()}),l({...Ve,toolCallType:z("FLOW"),displayName:a(),externalFlowId:a()}),l({...Ve,toolCallType:z("MCP"),displayName:a(),serverUrl:a()}),l({...Ve,toolCallType:z("KNOWLEDGE_BASE"),displayName:a(),sourceType:a()}),l({...Ve,toolCallType:z("UNKNOWN"),displayName:a()})]),ip=U([si,ui]);var Dr=(r=>(r.IMAGE="image",r.TEXT="text",r))(Dr||{}),be=l({apiKey:a()}),ap=be,sp=l({apiKey:a(),apiKeyHash:a()}),up=be,cp=be,pp=be,lp=be,dp=be,mp=be,fp=be,mi=l({accessKeyId:a().check(le(1)),secretAccessKey:a().check(le(1))}),gp=l({}),yp=l({}),hp=l({}),vp=l({}),_p=l({}),xp=l({}),fi=l({modelId:a(),modelName:a(),modelType:L(Dr)}),gi=l({apiKeyHeader:a(),baseUrl:a(),models:D(fi),defaultHeaders:y(N(a(),a()))}),yi=l({accountId:a(),gatewayId:a(),models:D(fi),vertexProject:y(a()),vertexRegion:y(a())}),hi=l({resourceName:a(),apiVersion:we(ze(e=>typeof e=="string"&&e.trim().length===0?void 0:e),y(a()))}),vi=l({region:a().check(le(1))}),Pp=U([ap,pp,lp,dp,mp,cp,up,sp,mi,fp]),_i=U([gi,yi,hi,vi,gp,hp,vp,_p,yp,xp]),bp=l({id:a(),name:a(),type:L(Dr)}),Tp=l({id:a(),name:a(),provider:L(vt),config:_i,enabledForChat:H()}),Ip=l({provider:L(vt),config:_i,auth:Pp,platformId:a()});var $I={openai:"openai",anthropic:"anthropic","google-ai-studio":"google","google-vertex-ai":"google"},ci=["gpt-5.5","gpt-5.4-mini","gpt-5.4-nano","gpt-4.1","gpt-4.1-mini"],Ep=["claude-sonnet-4-6","claude-opus-4-7","claude-haiku-4-5"],Sp=["claude-sonnet-4.6","claude-opus-4.7","claude-haiku-4.5"],pi=["gemini-2.5-pro","gemini-2.5-flash","gemini-3.1-pro-preview","gemini-3-flash-preview"],Ap=["grok-4.20","grok-4.1-fast"],$p={openai:ci,anthropic:Ep,google:pi,activepieces:[...Sp.map(e=>`anthropic/${e}`),...ci.map(e=>`openai/${e}`),...pi.map(e=>`google/${e}`),...Ap.map(e=>`x-ai/${e}`)]};var li=128e3,zp={openai:128e3,anthropic:2e5,google:1048576,bedrock:2e5,azure:128e3,openrouter:128e3,activepieces:2e5,mistral:128e3};function wp({provider:e}){return e?zp[e]??li:li}o(wp,"getMaxContextTokens");var di={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"},Op={anthropic:"native",google:"native",openrouter:"plugin",activepieces:"plugin"},kp=new Set(["anthropic","mistral"]);function fe(e){return{chatModels:$p[e],maxContextTokens:wp({provider:e}),defaultEmbeddingModel:di[e],supportsEmbedding:di[e]!==void 0,supportsImageGeneration:!kp.has(e),webSearch:Op[e]}}o(fe,"buildProviderCapabilities");var Rp={openai:fe("openai"),anthropic:fe("anthropic"),openrouter:fe("openrouter"),azure:fe("azure"),google:fe("google"),"cloudflare-gateway":fe("cloudflare-gateway"),custom:fe("custom"),bedrock:fe("bedrock"),mistral:fe("mistral"),activepieces:fe("activepieces")};var Np=l({base64Url:a(),fileName:a(),extension:y(a())}),Cp=l({mimeType:a(),url:a(),fileName:y(a())}),Ur=U([Np,Cp]);var Dp=U([l({type:z("file"),value:Ur}),l({type:z("markdown"),value:a(),files:y(D(Ur))})]),Up=l({sessionId:a(),message:a(),files:y(D(a()))});var Pi=(r=>(r.ON_NEW_RECORD="ON_NEW_RECORD",r.ON_UPDATE_RECORD="ON_UPDATE_RECORD",r))(Pi||{}),bi=(r=>(r.ENABLED="ENABLED",r.DISABLED="DISABLED",r))(bi||{}),Mr=(n=>(n.RECORD_CREATED="RECORD_CREATED",n.RECORD_UPDATED="RECORD_UPDATED",n.RECORD_DELETED="RECORD_DELETED",n))(Mr||{});var Mp=U([l({...ce,name:a(),externalId:a(),type:z("STATIC_DROPDOWN"),tableId:a(),projectId:a(),data:l({options:D(l({value:a()}))})}),l({...ce,name:a(),externalId:a(),type:U([z("TEXT"),z("NUMBER"),z("DATE")]),tableId:a(),projectId:a()})]),Lp=l({...ce,name:a(),folderId:G(a()),projectId:a(),externalId:a(),status:Or(bi),trigger:Or(Pi)}),jp=l({...ce,tableId:a(),projectId:a(),cells:N(a(),l({updated:a(),created:a(),value:R(),fieldName:a()}))}),Bp=l({events:D(L(Mr)),webhookUrl:a(),flowId:a()}),Fp=l({fields:D(l({id:a(),name:a()})),rows:D(N(a(),a())),name:a()}),Vp=l({projectId:a(),limit:y(at.number()),cursor:y(a()),name:y(a()),externalIds:Zt(a()),folderId:y(a()),folderIds:Zt(a())}),Zp=l({records:D(D(l({fieldId:a(),value:Ii()}))),tableId:a()}),Hp=l({cells:y(D(l({fieldId:a(),value:Ii()}))),tableId:a(),agentUpdate:y(H())}),Ti=$e("operator",[Ne("eq"),Ne("neq"),Ne("gt"),Ne("gte"),Ne("lt"),Ne("lte"),Ne("co"),xi("exists"),xi("not_exists")]),qp=l({tableId:a(),limit:y(at.number()),cursor:y(a()),filters:Zt(Ti)});function Ii(){return we(ze(e=>e==null?e:String(e)),it(a()))}o(Ii,"coerceToString");function Ne(e){return l({fieldId:a(),operator:z(e),value:a()})}o(Ne,"valueFilter");function xi(e){return l({fieldId:a(),operator:z(e)})}o(xi,"existenceFilter");var Gp=l({status:y(re()),body:y(R()),headers:y(N(a(),a()))}),Wp=l({...ce,deleted:G(Oe),ownerId:a(),displayName:a(),platformId:a(),externalId:G(a())});var Ei=l({name:a(),description:y(a()),type:a(),required:H()}),Kp=l({pieceName:a(),triggerName:a(),input:l({toolName:a(),toolDescription:a(),inputSchema:D(Ei),returnsResponse:H()})});var Si="^[0-9]+\\.[0-9]+\\.[0-9]+$",GI=new RegExp(Si),Xp="^([~^])?[0-9]+\\.[0-9]+\\.[0-9]+$",WI=a().check(Ae(new RegExp(Si))),KI=a().check(Ae(new RegExp(Xp))),Yp=l({packageType:z("ARCHIVE"),pieceType:L(Be),pieceName:a(),pieceVersion:a(),archiveId:a(),platformId:a()}),Ai=l({packageType:z("REGISTRY"),pieceType:z("OFFICIAL"),pieceName:a(),pieceVersion:a()}),$i=l({packageType:z("REGISTRY"),pieceType:z("CUSTOM"),pieceName:a(),pieceVersion:a(),platformId:a()}),JI=U([Ai,$i]),XI=U([Yp,Ai,$i]);var Qp=$e("type",[l({type:z("CRON_EXPRESSION"),cronExpression:a(),timezone:a()}),l({type:z("INTERVAL"),intervalMs:Bo().check(Ct(6e4))})]),YI=l({...ce,type:L(ee),projectId:a(),flowId:a(),triggerName:a(),schedule:G(Qp),flowVersionId:a(),pieceName:a(),pieceVersion:a(),deleted:G(a()),simulate:H()}),zi=(m=>(m.UNKNOWN="UNKNOWN",m.FLOW_RUN_LOG="FLOW_RUN_LOG",m.FLOW_RUN_LOG_SLICE="FLOW_RUN_LOG_SLICE",m.PACKAGE_ARCHIVE="PACKAGE_ARCHIVE",m.FLOW_STEP_FILE="FLOW_STEP_FILE",m.SAMPLE_DATA="SAMPLE_DATA",m.TRIGGER_PAYLOAD="TRIGGER_PAYLOAD",m.SAMPLE_DATA_INPUT="SAMPLE_DATA_INPUT",m.TRIGGER_EVENT_FILE="TRIGGER_EVENT_FILE",m.PROJECT_RELEASE="PROJECT_RELEASE",m.FLOW_VERSION_BACKUP="FLOW_VERSION_BACKUP",m.PLATFORM_ASSET="PLATFORM_ASSET",m.USER_PROFILE_PICTURE="USER_PROFILE_PICTURE",m.WEBHOOK_PAYLOAD="WEBHOOK_PAYLOAD",m.KNOWLEDGE_BASE="KNOWLEDGE_BASE",m.FLOW_BUNDLE="FLOW_BUNDLE",m))(zi||{}),wi=(r=>(r.NONE="NONE",r.ZSTD="ZSTD",r))(wi||{}),Oi=(r=>(r.S3="S3",r.DB="DB",r))(Oi||{}),QI=l({...ce,projectId:G(a()),platformId:G(a()),type:L(zi),compression:L(wi),data:y(R()),location:L(Oi),size:G(re()),fileName:G(a()),s3Key:G(a()),metadata:G(N(a(),a()))}),ki=(n=>(n.ADMIN="ADMIN",n.MEMBER="MEMBER",n.OPERATOR="OPERATOR",n))(ki||{}),Ri=(r=>(r.ACTIVE="ACTIVE",r.INACTIVE="INACTIVE",r))(Ri||{}),eE=l({id:a(),email:a(),firstName:a(),status:L(Ri),externalId:G(a()),platformId:G(a()),platformRole:L(ki),lastName:a(),created:Oe,updated:Oe,lastActiveDate:G(Oe),imageUrl:G(a())});var Lr=l({...Z.shape,...M(N(a(),R()),"OBJECT").shape});var Ui=l({...Z.shape,...M(a(),"COLOR").shape});var jr=U([ae,ve,Bt,xe,se,_e,Ar,st,$r,Pe,pt,Lr,lt,ct,ut,Ui]),f={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"}},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"}},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 ge=l({displayName:a(),description:y(a())});var Mi=l({username:a(),password:a()}),Br=l({...ge.shape,username:l({displayName:a(),description:y(a())}),password:l({displayName:a(),description:y(a())}),...M(Mi,"BASIC_AUTH").shape});var nl=N(a(),U([ae,ve,Pe,xe,se])),Fr=l({...ge.shape,props:nl,...M(R(),"CUSTOM_AUTH").shape});var Ce=l({...ge.shape,...M(l({auth:a()}),"SECRET_TEXT").shape});var ol=N(a(),U([ae,ve,Ce,Pe,xe,se,_e,Bt])),Li=l({...ge.shape,props:ol,...M(R(),"OIDC").shape});var Vr=(r=>(r.HEADER="HEADER",r.BODY="BODY",r))(Vr||{}),ji=U([ae,Ce,se]),Bi=N(a(),ji),il=l({props:y(N(a(),ji)),authUrl:a(),tokenUrl:a(),scope:D(a()),prompt:y(U([z("none"),z("consent"),z("login"),z("omit")])),pkce:y(H()),pkceMethod:y(U([z("plain"),z("S256")])),authorizationMethod:y(L(Vr)),grantType:y(U([L(ft),z(zr)])),extra:y(N(a(),a()))}),Fi=l({access_token:a(),props:y(Bi),data:N(a(),ot())}),Zr=l({...ge.shape,...il.shape,...M(Fi,"OAUTH2").shape});var Ze=U([Br,Fr,Li,Zr,Ce]),_t="Connection",Hr={SecretText(e){return{...e,valueSchema:void 0,type:"SECRET_TEXT"}},OAuth2(e){return{...e,valueSchema:void 0,type:"OAUTH2",displayName:e.displayName||_t}},BasicAuth(e){return{...e,valueSchema:void 0,type:"BASIC_AUTH",displayName:e.displayName||_t,required:!0}},CustomAuth(e){return{...e,valueSchema:void 0,type:"CUSTOM_AUTH",displayName:e.displayName||_t}},OIDC(e){return{...e,valueSchema:void 0,type:"OIDC",displayName:e.displayName||_t}},None(){}};var kS={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 al=l({...Z.shape,...M(R(),"CUSTOM").shape,code:a()});var sl=U([jr,Ze]),qr=N(a(),sl),YS=N(a(),jr);var Vi=U([l({strategy:z("CRON"),cronExpression:a()}),l({strategy:z("NONE")})]),He=class{constructor(t,r,n,i,u,c,p,h,v,P,$,x,s,d,g,m,_,b,B){this.name=t;this.displayName=r;this.description=n;this.requireAuth=i;this.props=u;this.type=c;this.handshakeConfiguration=p;this.onHandshake=h;this.renewConfiguration=v;this.onRenew=P;this.onEnable=$;this.onDisable=x;this.onStart=s;this.run=d;this.test=g;this.sampleData=m;this.testStrategy=_;this.outputSchema=b;this.aiMetadata=B}static{o(this,"ITrigger")}},J=o(e=>{switch(e.type){case"WEBHOOK":return new He(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);case"POLLING":return new He(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);case"MANUAL":return new He(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);case"APP_WEBHOOK":return new He(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,ue(e.sampleData)&&ue(e.test)?"SIMULATION":"TEST_FUNCTION",e.outputSchema,e.aiMetadata)}},"createTrigger");var Zi="2",qt="0.82.0";var Gr=class{constructor(t,r,n,i,u,c,p,h,v=qt,P,$="",x){this.displayName=t;this.logoUrl=r;this.authors=n;this.events=i;this.categories=p;this.auth=h;this.minimumSupportedRelease=v;this.maximumSupportedRelease=P;this.description=$;this.deprecated=x;this._actions={};this._triggers={};this.getContextInfo=o(()=>({version:Zi}),"getContextInfo");(!ul(v)||cl(v,qt))&&(this.minimumSupportedRelease=qt),u.forEach(s=>this._actions[s.name]=s),c.forEach(s=>this._triggers[s.name]=s)}static{o(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: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}},Hi=o(e=>{if(e.auth&&Array.isArray(e.auth)&&!e.auth.every((r,n,i)=>n===i.findIndex(u=>u.type===r.type)))throw new Error("Auth properties must be unique by type");return new Gr(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 ul(e){return/^\d+\.\d+\.\d+$/.test(e)}o(ul,"isValidSimpleSemver");function cl(e,t){let[r,n,i]=e.split(".").map(Number),[u,c,p]=t.split(".").map(Number);return r!==u?r<u:n!==c?n<c:i<p}o(cl,"isSemverLessThan");var pl=y(N(a(),N(a(),a()))),qi=l({id:y(a()),name:a(),displayName:a(),logoUrl:a(),description:a(),authors:D(a()),platformId:y(a()),directoryPath:y(a()),auth:y(U([Ze,D(Ze)])),version:a(),categories:y(D(L(mt))),minimumSupportedRelease:y(a()),maximumSupportedRelease:y(a()),deprecated:y(H()),i18n:pl}),ll=L(["human","ai","both"]),Gi=l({description:y(a()),idempotent:y(H())}),Wi=l({name:a(),displayName:a(),description:a(),props:qr,requireAuth:H(),errorHandlingOptions:y(Sr),outputSchema:y(Lt()),audience:y(ll),aiMetadata:y(Gi)}),Ki=l({name:a(),displayName:a(),description:a(),props:qr,errorHandlingOptions:y(Sr),type:L(ee),sampleData:R(),handshakeConfiguration:y(Lt()),renewConfiguration:y(Vi),testStrategy:L(yt),outputSchema:y(Lt()),aiMetadata:y(Gi)}),dl=l({...qi.shape,actions:N(a(),Wi),triggers:N(a(),Ki)}),ml=l({...qi.shape,actions:re(),triggers:re(),suggestedActions:y(D(Wi)),suggestedTriggers:y(D(Ki))}),Ji=l({projectUsage:re(),pieceType:L(Be),packageType:L(dt),platformId:y(a()),archiveId:y(a())}),YA=l({...dl.shape,...Ji.shape}),QA=l({...ml.shape,...Ji.shape}),e$=l({name:a(),version:a()});var fl=Me(require("path")),gl=Me(require("fs/promises"));var ea=require("node:stream");var Gt=class{constructor(t,r){this.baseUrl=t;this.authenticationConverter=r}static{o(this,"BaseHttpClient")}getUrl(t){let r=new URL(`${this.baseUrl}${t.url}`),n=`${r.origin}${r.pathname}`,i=new URLSearchParams;return r.searchParams.forEach((u,c)=>{i.append(c,u)}),{urlWithoutQueryParams:n,queryParams:i}}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 Wt=class{static{o(this,"DelegatingAuthenticationConverter")}constructor(t=new Wr,r=new Kr){this.converters={BEARER_TOKEN:t,BASIC:r}}convert(t,r){return this.converters[t.type].convert(t,r)}},Wr=class{static{o(this,"BearerTokenAuthenticationConverter")}convert(t,r){return r.Authorization=`Bearer ${t.token}`,r}},Kr=class{static{o(this,"BasicTokenAuthenticationConverter")}convert(t,r){let n=`${t.username}:${t.password}`,i=Buffer.from(n).toString("base64");return r.Authorization=`Basic ${i}`,r}};var xt=class extends Error{constructor(r,n){let i=n.status||500,u=Buffer.isBuffer(n.responseBody)?n.responseBody.toString():n.responseBody;super(JSON.stringify({response:{status:i,body:u},request:{body:r}}));this.requestBody=r;this.status=i,this.responseBody=u}static{o(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 Xi({error:e,requestBody:t}){return e instanceof xt?e.errorMessage():{response:{status:0,body:e instanceof Error?e.message:String(e)},request:{body:t}}}o(Xi,"toFailsafeOutput");var Kt=(c=>(c.GET="GET",c.POST="POST",c.PATCH="PATCH",c.PUT="PUT",c.DELETE="DELETE",c.HEAD="HEAD",c))(Kt||{});var Jt=class extends Gt{static{o(this,"FetchHttpClient")}constructor(t="",r=new Wt){super(t,r)}async sendRequest(t,r){process.env.NODE_TLS_REJECT_UNAUTHORIZED="0";let{urlWithoutQueryParams:n,queryParams:i}=this.getUrl(t),u=this.getHeaders(t),c=t.queryParams??{};for(let[B,ie]of Object.entries(c))i.append(B,ie);let p=i.toString(),h=p?`${n}?${p}`:n,v=t.responseType??"json",P=t.followRedirects??!0,$=t.retries??0,{body:x,extraHeaders:s,isStream:d}=yl(t.method)?hl(t.body,u):{body:void 0,extraHeaders:{},isStream:!1},g=_l({...u,...s}),m=await vl(async()=>{let B=new AbortController,ie=t.timeout&&t.timeout>0?setTimeout(()=>B.abort(),t.timeout):void 0;try{let pe={method:t.method.toString(),headers:g,body:x,redirect:P?"follow":"manual",signal:B.signal};return d&&(pe.duplex="half"),r?.dispatcher!==void 0&&(pe.dispatcher=r.dispatcher),await fetch(h,pe)}finally{ie!==void 0&&clearTimeout(ie)}},$),_=P?300:400;if(m.status<200||m.status>=_){let B=await Yi(m,v),ie=new xt(t.body,{status:m.status,responseBody:B});throw console.error("[HttpClient#(sanitized error message)] Request failed:",ie),ie}let b=await Yi(m,v);return{status:m.status,headers:xl(m.headers),body:b}}};function yl(e){return e!=="GET"&&e!=="HEAD"}o(yl,"acceptsRequestBody");function hl(e,t){if(bl(e))return{body:void 0,extraHeaders:{},isStream:!1};if(Pl(e)){let n=new ea.PassThrough;return e.on("error",i=>n.destroy(i)),e.pipe(n),{body:n,extraHeaders:e.getHeaders(),isStream:!0}}return 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}}o(hl,"serializeBody");async function Yi(e,t){switch(t){case"arraybuffer":return Buffer.from(await e.arrayBuffer());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}}}}o(Yi,"parseResponseBody");async function vl(e,t){let r;for(let n=0;n<=t;n++)try{let i=await e();if(i.status>=500&&n<t){await Qi(n);continue}return i}catch(i){if(r=i,n<t){await Qi(n);continue}throw i}throw r}o(vl,"sendWithRetries");function Qi(e){let t=Math.min(1e3*2**e,3e4);return new Promise(r=>setTimeout(r,t))}o(Qi,"backoff");function _l(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}o(_l,"normalizeHeaders");function xl(e){let t={};return e.forEach((r,n)=>{t[n]=r}),t}o(xl,"toHttpHeaders");function Pl(e){return typeof e=="object"&&e!==null&&typeof e.getHeaders=="function"&&typeof e.pipe=="function"&&typeof e.on=="function"}o(Pl,"isNodeFormData");function bl(e){return e==null}o(bl,"isNil");var Xt=new Jt;var cm=Me(require("fs")),au=Me(iu());var pm={"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 lm(e){let t=e.split(";")[0].trim().toLowerCase();return pm[t]??""}o(lm,"contentTypeToExtension");var dm=o(({baseUrl:e,relativePath:t})=>{let r=e.endsWith("/")?e:`${e}/`,n=t.startsWith("/")?t.slice(1):t;return`${r}${n}`},"joinBaseUrlWithRelativePath"),mm=o((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 su({auth:e,baseUrl:t,authMapping:r,description:n,displayName:i,name:u,props:c,extraProps:p,authLocation:h="headers"}){return V({audience:"human",name:u||"custom_api_call",displayName:i||"Custom API Call",description:n||"Make a custom API call to a specific endpoint",auth:e,requireAuth:!!e,props:{url:f.DynamicProperties({auth:e,displayName:"",required:!0,refreshers:[],props:o(async({auth:v})=>({url:f.ShortText({displayName:"URL",description:`You can either use the full URL or the relative path to the base URL
|
|
3
|
+
i.e ${mm(t,v)}/resource or /resource`,required:!0,defaultValue:v?t(v):"",...c?.url??{}})}),"props")}),method:f.StaticDropdown({displayName:"Method",required:!0,options:{options:Object.values(Kt).map(v=>({label:v,value:v}))},...c?.method??{}}),headers:f.Object({displayName:"Headers",description:"Authorization headers are injected automatically from your connection.",required:!0,...c?.headers??{}}),queryParams:f.Object({displayName:"Query Parameters",required:!0,...c?.queryParams??{}}),body_type:f.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:f.DynamicProperties({auth:e,displayName:"Body",refreshers:["body_type"],required:!1,props:o(async({body_type:v})=>{if(!v)return{};let P=v,$={};switch(P){case"none":break;case"json":$.data=f.Json({displayName:"JSON Body",required:!0,...c?.body??{}});break;case"raw":$.data=f.LongText({displayName:"Raw Body",required:!0});break;case"form_data":$.data=f.Array({displayName:"Form Data",required:!0,properties:{fieldName:f.ShortText({displayName:"Field Name",required:!0}),fieldType:f.StaticDropdown({displayName:"Field Type",required:!0,options:{disabled:!1,options:[{label:"Text",value:"text"},{label:"File",value:"file"}]}}),textFieldValue:f.LongText({displayName:"Text Field Value",required:!1}),fileFieldValue:f.File({displayName:"File Field Value",required:!1})}});break}return $},"props")}),response_is_binary:f.Checkbox({displayName:"Response is Binary ?",description:"Enable for files like PDFs, images, etc.",required:!1,defaultValue:!1}),failsafe:f.Checkbox({displayName:"No Error on Failure",required:!1,...c?.failsafe??{}}),timeout:f.Number({displayName:"Timeout (in seconds)",required:!1,...c?.timeout??{}}),followRedirects:f.Checkbox({displayName:"Follow redirects",required:!1,defaultValue:!1}),...p},run:o(async v=>{let{method:P,url:$,headers:x,queryParams:s,body:d,body_type:g,failsafe:m,timeout:_,response_is_binary:b,followRedirects:B}=v.propsValue;Vt(P,"Method"),Vt($,"URL");let ie=ue(r)?{}:await r(v.auth,v.propsValue),pe=$.url,Xe=pe.startsWith("http://")||pe.startsWith("https://")?pe:dm({baseUrl:t(v.auth),relativePath:pe}),Te={method:P,url:Xe,headers:{...x??{},...h==="headers"||!ue(h)?ie:{}},queryParams:{...h==="queryParams"?ie:{},...s??{}},timeout:_?_*1e3:0,followRedirects:B};if(b&&(Te.responseType="arraybuffer"),d)if(g&&g!=="none"){let ye=d.data;if(g==="form_data"){let Cu=ye,It=new au.default;for(let{fieldName:$n,fieldType:zn,textFieldValue:wn,fileFieldValue:pr}of Cu)zn==="text"&&!ht(wn)?It.append($n,wn):zn==="file"&&!ht(pr)&&It.append($n,pr.data,{filename:pr?.filename});Te.body=It,Te.headers={...Te.headers,...It.getHeaders()}}else Te.body=ye}else g||(Te.body=d);try{let ye=await Xt.sendRequest(Te);return await fm(v.files,ye.body,ye.status,ye.headers,b)}catch(ye){if(m)return Xi({error:ye,requestBody:Te.body});throw ye}},"run")})}o(su,"createCustomApiCallAction");var fm=o(async(e,t,r,n,i)=>{let u;if(i&&gm(t)){let c=Array.isArray(n?.["content-type"])?n["content-type"][0]:n?.["content-type"],p=lm(c??"")||"txt",h;t instanceof ArrayBuffer?h=Buffer.from(new Uint8Array(t)):Buffer.isBuffer(t)?h=t:h=Buffer.from(t),u=await e.write({fileName:`output.${p}`,data:h})}else u=t;return{status:r,headers:n,body:u}},"handleBinaryResponse"),gm=o(e=>e instanceof ArrayBuffer||Buffer.isBuffer(e),"isBinaryBody");var sr=o(e=>`https://api.bigcommerce.com/stores/${e}`,"GET_BASE_URL");function Ue(e){return{disabled:!0,options:[],placeholder:e}}o(Ue,"handleDropdownError");async function oe({method:e,path:t,body:r,auth:n,filter:i=!1}){let u=sr(n.storeHash),c=i&&r?Array.isArray(r)?r.map(p=>ur(p)):ur(r):r;return await Xt.sendRequest({method:e,url:`${u}${t}`,headers:{"X-Auth-Token":n.accessToken,"Content-Type":"application/json",Accept:"application/json"},body:c}).then(p=>p.body).catch(p=>{throw new Error(`Error in request to ${t}: ${p.message||JSON.stringify(p)}`)})}o(oe,"fireHttpRequest");var T={async createWebhook({auth:e,payload:t}){return await oe({auth:e,path:"/v3/hooks",method:"POST",body:t})},async createCustomer({auth:e,payload:t}){return await oe({auth:e,path:"/v3/customers",method:"POST",body:t})},async fetchCustomers({auth:e,queryString:t}){return await oe({auth:e,path:`/v3/customers${t?`?${t}`:""}`,method:"GET"})},async fetchCustomerAddresses({auth:e,queryString:t}){return await oe({auth:e,path:`/v3/customers/addresses${t?`?${t}`:""}`,method:"GET"})},async fetchProducts({auth:e,queryString:t}){return await oe({auth:e,path:`/v3/catalog/products${t?`?${t}`:""}`,method:"GET"})},async createProduct({auth:e,payload:t}){return await oe({auth:e,path:"/v3/catalog/products",method:"POST",body:t,filter:!0})},async updateProduct({auth:e,productId:t,payload:r}){return await oe({auth:e,path:`/v3/catalog/products/${t}`,method:"PUT",body:r,filter:!0})},async deleteProduct({auth:e,productId:t}){return await oe({auth:e,path:`/v3/catalog/products/${t}`,method:"DELETE"})},async fetchOrders({auth:e,queryString:t}){return await oe({auth:e,path:`/v2/orders${t?`?${t}`:""}`,method:"GET"})},async fetchOrder({auth:e,orderId:t}){return await oe({auth:e,path:`/v2/orders/${t}`,method:"GET"})},async fetchCategories({auth:e,queryString:t}){return await oe({auth:e,path:`/v3/catalog/categories${t?`?${t}`:""}`,method:"GET"})},async createBlogPost({auth:e,payload:t}){return await oe({auth:e,path:"/v2/blog/posts",method:"POST",body:t})},async createCustomerAddress({auth:e,payload:t}){return await oe({auth:e,path:"/v3/customers/addresses",method:"POST",body:t})},async deleteWebhook({auth:e,webhookId:t}){return await oe({auth:e,path:`/v3/hooks/${t}`,method:"DELETE"})}};function ur(e){if(e!=null)return typeof e!="object"?e:Array.isArray(e)?e.map(ur):Object.fromEntries(Object.entries(e).filter(([t,r])=>r!=null).map(([t,r])=>[t,ur(r)]))}o(ur,"filterNulls");var E=Hr.CustomAuth({description:"Enter your BigCommerce API credentials. ",props:{instruction:f.MarkDown({value:`1. Login to https://www.bigcommerce.com/essentials/
|
|
4
4
|
2. Go to Settings
|
|
5
5
|
3. Scroll down to API
|
|
6
6
|
4. Click on "Store Level API Accounts"
|
|
7
7
|
5. Click "Create API Account" button
|
|
8
8
|
6. Enter a name and add required scopes
|
|
9
|
-
7. Save - you will get a downloaded file containing your access token and store hash`}),storeHash:f.ShortText({displayName:"Store Hash",description:"Your BigCommerce store hash (e.g., abcd1234)",required:!0}),accessToken:f.ShortText({displayName:"Access Token",description:"Your BigCommerce API access token",required:!0})},required:!0,async validate(e){try{return await T.fetchProducts({auth:e.auth}),{valid:!0}}catch{return{valid:!1,error:"Could not validate credentials. please check your credentials are correct."}}}});var Kd="abandoned cart",fn=`${Kd}-trigger-store-key`,Jd="store/cart/abandoned",Gs=J({auth:I,name:"abandonedCart",displayName:"Abandoned Cart",description:"Triggers when a cart is abandoned",aiMetadata:{description:"Fires when a shopper abandons a cart in the BigCommerce store (the cart sits inactive without checkout completing). The event identifies the affected cart; use it to drive abandoned-cart recovery flows."},props:{},sampleData:{producer:"stores/dxqdddcaklwsso",hash:"3610addd127e330084ddddd7ddd09b78abfd1a85",created_at:1761809622,store_id:"1003425529",scope:"store/cart/abandoned",data:{type:"cart",id:"ss-598f-4c95-813b-0ess950562770d"}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:Jd,destination:e.webhookUrl,is_active:!0}});await e.store.put(fn,t.data.id)},async onDisable(e){let t=await e.store.get(fn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(fn)})},async run(e){return[e.payload.body]}});var Xd="cart created",gn=`${Xd}-trigger-store-key`,Yd="store/cart/created",Ks=J({auth:I,name:"cartCreated",displayName:"Cart Created",description:"Triggers when a new cart is created",aiMetadata:{description:"Fires when a new shopping cart is created in the BigCommerce store (a shopper adds the first item to a fresh cart). The event identifies the new cart."},props:{},sampleData:{producer:"stores/dxqdddcaklwsso",hash:"3610addd127e330084ddddd7ddd09b78abfd1a85",created_at:1761809622,store_id:"1003425529",scope:"store/cart/created",data:{type:"cart",id:"ss-598f-4c95-813b-0ess950562770d"}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:Yd,destination:e.webhookUrl,is_active:!0}});await e.store.put(gn,t.data.id)},async onDisable(e){let t=await e.store.get(gn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(gn)})},async run(e){return[e.payload.body]}});var Qd="customer address created",yn=`${Qd}-trigger-store-key`,em="store/customer/address/created",Js=J({auth:I,name:"customerAddressCreated",displayName:"Customer Address Created",description:"Triggers when a new customer address is created",aiMetadata:{description:"Fires when a new address is added to a customer in the BigCommerce store. The event identifies the affected customer."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/customer/address/created",data:{type:"customer",id:2}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:em,destination:e.webhookUrl,is_active:!0}});await e.store.put(yn,t.data.id)},async onDisable(e){let t=await e.store.get(yn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(yn)})},async run(e){return[e.payload.body]}});var tm="customer address updated",hn=`${tm}-trigger-store-key`,rm="store/customer/address/updated",Xs=J({auth:I,name:"customerAddressUpdated",displayName:"Customer Address Updated",description:"Triggers when a new customer address is updated",aiMetadata:{description:"Fires when an existing customer address is updated in the BigCommerce store. The event identifies the affected customer."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/customer/address/updated",data:{type:"customer",id:2}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:rm,destination:e.webhookUrl,is_active:!0}});await e.store.put(hn,t.data.id)},async onDisable(e){let t=await e.store.get(hn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(hn)})},async run(e){return[e.payload.body]}});var nm="customer created",vn=`${nm}-trigger-store-key`,om="store/customer/created",Ys=J({auth:I,name:"customerCreated",displayName:"Customer Created",description:"Triggers when a new customer is created",aiMetadata:{description:"Fires when a new customer is created in the BigCommerce store. The event identifies the new customer."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/customer/created",data:{type:"customer",id:2,origin_channel_id:1,channel_ids:[1]}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:om,destination:e.webhookUrl,is_active:!0}});await e.store.put(vn,t.data.id)},async onDisable(e){let t=await e.store.get(vn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(vn)})},async run(e){return[e.payload.body]}});var im="customer updated",xn=`${im}-trigger-store-key`,am="store/customer/updated",Qs=J({auth:I,name:"customerUpdated",displayName:"Customer Updated",description:"Triggers when a customer is updated",aiMetadata:{description:"Fires when an existing customer record is updated in the BigCommerce store. The event identifies the affected customer."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/customer/updated",data:{type:"customer",id:2}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:am,destination:e.webhookUrl,is_active:!0}});await e.store.put(xn,t.data.id)},async onDisable(e){let t=await e.store.get(xn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(xn)})},async run(e){return[e.payload.body]}});var sm="order created",_n=`${sm}-trigger-store-key`,um="store/order/created",eu=J({auth:I,name:"orderCreated",displayName:"Order Created",description:"Triggers when a new order is created",aiMetadata:{description:"Fires when a new order is created in the BigCommerce store. The event identifies the new order; pair with Get Order to fetch its full details."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/order/created",data:{type:"order",id:2}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:um,destination:e.webhookUrl,is_active:!0}});await e.store.put(_n,t.data.id)},async onDisable(e){let t=await e.store.get(_n);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(_n)})},async run(e){return[e.payload.body]}});var cm="order updated",Pn=`${cm}-trigger-store-key`,pm="store/order/updated",tu=J({auth:I,name:"orderUpdated",displayName:"Order Updated",description:"Triggers when an order is updated",aiMetadata:{description:"Fires when an existing order is updated in the BigCommerce store (any change to the order, not just its status). The event identifies the affected order; pair with Get Order for full details."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/order/updated",data:{type:"order",id:2}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:pm,destination:e.webhookUrl,is_active:!0}});await e.store.put(Pn,t.data.id)},async onDisable(e){let t=await e.store.get(Pn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(Pn)})},async run(e){return[e.payload.body]}});var lm="order status updated",bn=`${lm}-trigger-store-key`,dm="store/order/statusUpdated",ru=J({auth:I,name:"orderStatusUpdated",displayName:"Order Status Updated",description:"Triggers when an order status has changed",aiMetadata:{description:"Fires specifically when an order\u2019s status changes in the BigCommerce store (e.g. moves to shipped or completed). Use this instead of Order Updated when you only care about status transitions. The event identifies the affected order."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/order/statusUpdated",data:{type:"order",id:2}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:dm,destination:e.webhookUrl,is_active:!0}});await e.store.put(bn,t.data.id)},async onDisable(e){let t=await e.store.get(bn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(bn)})},async run(e){return[e.payload.body]}});var mm="product created",Tn=`${mm}-trigger-store-key`,fm="store/product/created",nu=J({auth:I,name:"productCreated",displayName:"Product Created",description:"Triggers when a new product is created",aiMetadata:{description:"Fires when a new product is added to the BigCommerce store catalog. The event identifies the new product."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"c6db17090e98d2c58c0cb1988b5e9ace48215e22",created_at:1761808831,store_id:"1003425529",scope:"store/product/created",data:{type:"product",id:113}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:fm,destination:e.webhookUrl,is_active:!0}});await e.store.put(Tn,t.data.id)},async onDisable(e){let t=await e.store.get(Tn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(Tn)})},async run(e){return[e.payload.body]}});var gm="shipment created",In=`${gm}-trigger-store-key`,ym="store/shipment/created",ou=J({auth:I,name:"shipmentCreated",displayName:"Shipment Created",description:"Triggers when a new shipment is created",aiMetadata:{description:"Fires when a new shipment is created for an order in the BigCommerce store (items are shipped/fulfilled). The event identifies the new shipment."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/shipment/created",data:{type:"shipment",id:2}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:ym,destination:e.webhookUrl,is_active:!0}});await e.store.put(In,t.data.id)},async onDisable(e){let t=await e.store.get(In);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(In)})},async run(e){return[e.payload.body]}});var iu=V({auth:I,name:"createCustomer",displayName:"Create Customer",description:"Creates a customer",audience:"both",aiMetadata:{description:"Creates a new customer record in a BigCommerce store from an email plus first/last name (company, phone, and notes optional). Use to register a shopper or contact. Not idempotent: each call adds a new customer, and BigCommerce rejects a duplicate email rather than returning the existing one, so call Search Customer or Find or Create Customer first if the customer may already exist.",idempotent:!1},props:{email:f.ShortText({displayName:"Email",description:"Customer email address",required:!0}),first_name:f.ShortText({displayName:"First Name",description:"Customer first name",required:!0}),last_name:f.ShortText({displayName:"Last Name",description:"Customer last name",required:!0}),company:f.ShortText({displayName:"Company",description:"Customer company name",required:!1}),phone:f.ShortText({displayName:"Phone",description:"Customer phone number",required:!1}),notes:f.LongText({displayName:"Notes",description:"Customer notes",required:!1})},async run(e){return await T.createCustomer({auth:e.auth.props,payload:[{email:e.propsValue.email,first_name:e.propsValue.first_name,last_name:e.propsValue.last_name,company:e.propsValue.company,phone:e.propsValue.phone,notes:e.propsValue.notes}]})}});var au=V({auth:I,name:"createAProduct",displayName:"Create a Product",description:"Creates a Product",audience:"both",aiMetadata:{description:"Creates a new catalog product in a BigCommerce store. Use to add an item to the store. Requires name, type (physical or digital), weight, and price; SKU, description, and brand_id are optional. Not idempotent: each call adds a new product, so search the catalog first if it may already exist.",idempotent:!1},props:{name:f.ShortText({displayName:"Product Name",description:"Name of the product",required:!0}),type:f.StaticDropdown({displayName:"Product Type",description:"Type of product",required:!0,options:{options:[{label:"Physical",value:"physical"},{label:"Digital",value:"digital"}]}}),sku:f.ShortText({displayName:"SKU",description:"Product SKU",required:!1}),description:f.LongText({displayName:"Description",description:"Product description",required:!1}),weight:f.Number({displayName:"Weight",description:"Product weight",required:!0}),price:f.Number({displayName:"Price",description:"Product price",required:!0}),brand_id:f.Number({displayName:"Brand ID",description:"Brand ID",required:!1})},async run(e){return await T.createProduct({auth:e.auth.props,payload:{name:e.propsValue.name,type:e.propsValue.type,sku:e.propsValue.sku,description:e.propsValue.description,weight:e.propsValue.weight,price:e.propsValue.price,brand_id:e.propsValue.brand_id}})}});var su=V({auth:I,name:"updateAProduct",displayName:"Update a Product",description:"Updates an existing Product",audience:"both",aiMetadata:{description:"Updates an existing catalog product in a BigCommerce store, identified by its productId. Only the fields you supply are sent (null/undefined values are dropped so existing data is preserved), so use it for partial edits to name, type, SKU, description, weight, price, or brand. Idempotent: re-applying the same field values leaves the product in the same state.",idempotent:!0},props:{productId:f.ShortText({displayName:"Product ID",description:"The ID of the product to update",required:!0}),name:f.ShortText({displayName:"Product Name",description:"Name of the product",required:!1}),type:f.StaticDropdown({displayName:"Product Type",description:"Type of product",required:!1,options:{options:[{label:"Physical",value:"physical"},{label:"Digital",value:"digital"}]}}),sku:f.ShortText({displayName:"SKU",description:"Product SKU",required:!1}),description:f.LongText({displayName:"Description",description:"Product description",required:!1}),weight:f.Number({displayName:"Weight",description:"Product weight",required:!1}),price:f.Number({displayName:"Price",description:"Product price",required:!1}),brand_id:f.Number({displayName:"Brand ID",description:"Brand ID",required:!1})},async run(e){let{productId:t,...r}=e.propsValue,n=Object.fromEntries(Object.entries(r).filter(([i,u])=>u!=null));return await T.updateProduct({auth:e.auth.props,productId:t,payload:n})}});var uu=V({auth:I,name:"deleteAProduct",displayName:"Delete a Product",description:"Deletes an existing Product",audience:"both",aiMetadata:{description:"Permanently deletes a catalog product from a BigCommerce store by its productId. Use to remove an item from the store. This is destructive and cannot be undone. Effectively idempotent: deleting an already-removed product has no further effect, though the call may error if the id no longer exists.",idempotent:!0},props:{productId:f.ShortText({displayName:"Product ID",description:"The ID of the product to delete",required:!0})},async run(e){return await T.deleteProduct({auth:e.auth.props,productId:e.propsValue.productId})}});var cu=V({auth:I,name:"getOrder",displayName:"Get Order",description:"Gets details of an order",audience:"both",aiMetadata:{description:"Retrieves the full details of a single BigCommerce order by its orderId. Use when you already have an order id (e.g. from an order trigger or List Orders) and need its data. Idempotent read-only lookup with no side effects.",idempotent:!0},props:{orderId:f.ShortText({displayName:"Order ID",description:"The ID of the order to retrieve",required:!0})},async run(e){return await T.fetchOrder({auth:e.auth.props,orderId:e.propsValue.orderId})}});var pu=V({auth:I,name:"listOrders",displayName:"List Orders",description:"Lists all orders",audience:"both",aiMetadata:{description:"Lists orders from a BigCommerce store. With no filters it returns all orders; optionally narrow by customer_id and/or status_id to a subset. Use to browse or find orders when you do not have a specific order id. Idempotent read-only query with no side effects.",idempotent:!0},props:{customer_id:f.Number({displayName:"Customer ID",description:"Filter by customer ID",required:!1}),status_id:f.Number({displayName:"Status ID",description:"Filter by status ID",required:!1})},async run(e){let t=new URLSearchParams;return e.propsValue.customer_id!==void 0&&e.propsValue.customer_id!==null&&t.append("customer_id",e.propsValue.customer_id.toString()),e.propsValue.status_id!==void 0&&e.propsValue.status_id!==null&&t.append("status_id",e.propsValue.status_id.toString()),await T.fetchOrders({auth:e.auth.props,queryString:t.toString()})}});var lu=V({auth:I,name:"listCategories",displayName:"List Categories",description:"Lists all categories",audience:"both",aiMetadata:{description:"Lists product categories from a BigCommerce store. With no name filter it returns all categories; provide a name to filter to matching categories. Use to discover category names or ids before assigning products. Idempotent read-only query with no side effects.",idempotent:!0},props:{name:f.ShortText({displayName:"Category Name",description:"Filter by category name",required:!1})},async run(e){let t=new URLSearchParams;return e.propsValue.name&&t.append("name",e.propsValue.name),await T.fetchCategories({auth:e.auth.props,queryString:t.toString()})}});var du=V({auth:I,name:"createBlogPost",displayName:"Create Blog Post",description:"Creates a blog post",audience:"both",aiMetadata:{description:"Creates a blog post in a BigCommerce store's blog. Requires a title and body (HTML supported); author, URL, published date, meta description/keywords, tags, and a published flag are optional. Use to publish store blog content. Not idempotent: each call creates a new post.",idempotent:!1},props:{title:f.ShortText({displayName:"Title",description:"Blog post title",required:!0}),body:f.LongText({displayName:"Body",description:"Blog post content (HTML supported)",required:!0}),author:f.ShortText({displayName:"Author",description:"Author name",required:!1}),url:f.ShortText({displayName:"URL",description:"URL for the public blog post. Example - /blog/welcome-bigcommerce/",required:!1}),published_date:f.DateTime({displayName:"Published Date",description:"Published Date for the blog post. Example - Wed, 10 Aug 2022 15:39:15 -0500",required:!1}),meta_description:f.LongText({displayName:"Meta Description",description:"Description text for this blog post\u2019s <meta/> element.",required:!1}),meta_keywords:f.LongText({displayName:"Meta Keywords",description:"Comma seperated (,) Keywords for this blog post\u2019s <meta/> element. Eg welcome, bigcommerce",required:!1}),tags:f.Array({displayName:"Tags",description:"Array of tags",required:!1}),is_published:f.Checkbox({displayName:"Is Published",description:"Whether the post is published",required:!1,defaultValue:!0})},async run(e){return await T.createBlogPost({auth:e.auth.props,payload:{title:e.propsValue.title,body:e.propsValue.body,author:e.propsValue.author,tags:e.propsValue.tags,is_published:e.propsValue.is_published,meta_description:e.propsValue.meta_description,meta_keywords:e.propsValue.meta_keywords,published_date:e.propsValue.published_date,url:e.propsValue.url}})}});var ar=o(({required:e})=>f.Dropdown({auth:I,displayName:"Customer",description:"Select the customer",required:e,refreshers:["auth"],options:o(async({auth:t})=>{if(!t)return Re("Please connect your account first");try{let r=await T.fetchCustomers({auth:t.props}),n=Array.isArray(r?.data)?r.data:[];return n.length===0?Re("No customers found"):{disabled:!1,options:n.map(u=>({label:[u.first_name,u.last_name].filter(l=>typeof l=="string"&&l.trim()!=="").join(" ")||u.email||u.id,value:u.id}))}}catch{return Re("Failed to load customers")}},"options")}),"customerDropdown"),mu=o(({required:e})=>f.MultiSelectDropdown({auth:I,displayName:"Customers",description:"Select the customers",required:e,refreshers:["auth"],options:o(async({auth:t})=>{if(!t)return Re("Please connect your account first");try{let r=await T.fetchCustomers({auth:t.props}),n=Array.isArray(r?.data)?r.data:[];return n.length===0?Re("No customers found"):{disabled:!1,options:n.map(u=>({label:[u.first_name,u.last_name].filter(l=>typeof l=="string"&&l.trim()!=="").join(" ")||u.email||u.id,value:u.id}))}}catch{return Re("Failed to load customers")}},"options")}),"multiCustomerDropdown");var fu=V({auth:I,name:"createCustomerAddress",displayName:"Create Customer Address",description:"Creates a customer's address",audience:"both",aiMetadata:{description:"Adds a new address to an existing BigCommerce customer, identified by customer_id (selected from a dropdown of store customers). Requires name, address line 1, city, state/province, postal code, and an ISO 3166-1 alpha-2 country code. Use to attach a shipping or billing address to a customer. Not idempotent: each call appends a new address even if an identical one exists, so use Find or Create Customer\u2019s Address to avoid duplicates.",idempotent:!1},props:{customer_id:ar({required:!0}),first_name:f.ShortText({displayName:"First Name",required:!0}),last_name:f.ShortText({displayName:"Last Name",required:!0}),address1:f.ShortText({displayName:"Address Line 1",required:!0}),address2:f.ShortText({displayName:"Address Line 2",required:!1}),city:f.ShortText({displayName:"City",required:!0}),state_or_province:f.ShortText({displayName:"State/Province",required:!0}),postal_code:f.ShortText({displayName:"Postal Code",required:!0}),country_code:f.ShortText({displayName:"Country Code",description:"ISO 3166-1 alpha-2 country code",required:!0}),phone:f.ShortText({displayName:"Phone",required:!1})},async run(e){return await T.createCustomerAddress({auth:e.auth.props,payload:[{customer_id:e.propsValue.customer_id,first_name:e.propsValue.first_name,last_name:e.propsValue.last_name,address1:e.propsValue.address1,address2:e.propsValue.address2,city:e.propsValue.city,state_or_province:e.propsValue.state_or_province,postal_code:e.propsValue.postal_code,country_code:e.propsValue.country_code,phone:e.propsValue.phone}]})}});var gu=V({auth:I,name:"searchCustomer",displayName:"Search Customer",description:"Searches for a registered customer",audience:"both",aiMetadata:{description:"Searches registered customers in a BigCommerce store by email, phone, and/or name. With no filters it returns all customers; supplying any filter narrows to matches. Use to look up a customer or check whether one exists before creating it. Idempotent read-only query with no side effects.",idempotent:!0},props:{email:f.ShortText({displayName:"Email",description:"Customer email to search for",required:!1}),phone:f.ShortText({displayName:"Phone Number",description:"Phone Number to search for",required:!1}),name:f.ShortText({displayName:"Name",description:"Customer name to search for",required:!1})},async run(e){let t=new URLSearchParams;return e.propsValue.email&&t.append("email:in",e.propsValue.email),e.propsValue.name&&t.append("name:in",`${e.propsValue.name}`),e.propsValue.phone&&t.append("phone:in",e.propsValue.phone),await T.fetchCustomers({auth:e.auth.props,queryString:t.toString()})}});var yu=V({auth:I,name:"searchProduct",displayName:"Search Product",description:"Searches for a product in the catalog",audience:"both",aiMetadata:{description:"Searches the BigCommerce product catalog by name, SKU, type, brand, weight, and/or price. With no filters it returns all products; supplying any filter narrows to matches. Use to find a product or its id, or to check whether one exists before creating it. Idempotent read-only query with no side effects.",idempotent:!0},props:{name:f.ShortText({displayName:"Product Name",description:"Product name to search for",required:!1}),sku:f.ShortText({displayName:"SKU",description:"Product SKU to search for",required:!1}),type:f.StaticDropdown({displayName:"Product Type",required:!1,options:{options:[{label:"Physical",value:"physical"},{label:"Digital",value:"digital"}]}}),brand_id:f.ShortText({displayName:"Brand ID",description:"Brand ID to search for",required:!1}),weight:f.Number({displayName:"Weight",required:!1}),price:f.Number({displayName:"Price",required:!1})},async run(e){let t=new URLSearchParams;return e.propsValue.name&&t.append("name",e.propsValue.name),e.propsValue.sku&&t.append("sku",e.propsValue.sku),e.propsValue.brand_id&&t.append("brand_id",e.propsValue.brand_id),e.propsValue.type&&t.append("type",e.propsValue.type),e.propsValue.price&&t.append("price",String(e.propsValue.price)),e.propsValue.weight&&t.append("weight",String(e.propsValue.weight)),await T.fetchProducts({auth:e.auth.props,queryString:t.toString()})}});var hu=V({auth:I,name:"searchCustomerAddress",displayName:"Search Customer Address",description:"Searches for a customer\u2019s address",audience:"both",aiMetadata:{description:"Searches customer addresses in a BigCommerce store, optionally filtered by one or more customer ids and/or a name. With no filters it returns all addresses; supplying filters narrows to matches. Use to look up addresses belonging to specific customers. Idempotent read-only query with no side effects.",idempotent:!0},props:{customer_ids:mu({required:!1}),name:f.ShortText({displayName:"Name",description:"Customer name to search for",required:!1})},async run(e){let t=new URLSearchParams;return e.propsValue.customer_ids&&t.append("customer_ids:in",e.propsValue.customer_ids.join(",")),e.propsValue.name&&t.append("name:in",`${e.propsValue.name}`),await T.fetchCustomerAddresses({auth:e.auth.props,queryString:t.toString()})}});var vu=V({auth:I,name:"findOrCreateCustomer",displayName:"Find or Create Customer",description:"Finds or creates a customer",audience:"both",aiMetadata:{description:"Looks up a BigCommerce customer by email (and phone if given) and returns the match if found, otherwise creates a new customer from the supplied details. Use this instead of Create Customer when the customer may already exist, to avoid duplicate-email errors. Idempotent: repeated calls match the same existing record rather than creating duplicates.",idempotent:!0},props:{email:f.ShortText({displayName:"Email",description:"Customer email address",required:!0}),first_name:f.ShortText({displayName:"First Name",description:"Customer first name",required:!0}),last_name:f.ShortText({displayName:"Last Name",description:"Customer last name",required:!0}),company:f.ShortText({displayName:"Company",description:"Customer company name",required:!1}),phone:f.ShortText({displayName:"Phone",description:"Customer phone number",required:!1}),notes:f.LongText({displayName:"Notes",description:"Customer notes",required:!1})},async run(e){let t=new URLSearchParams;t.append("email:in",e.propsValue.email),e.propsValue.phone&&t.append("phone:in",e.propsValue.phone);let r=await T.fetchCustomers({auth:e.auth.props,queryString:t.toString()});return r.data&&r.data.length>0?{found:!0,data:r.data}:{found:!1,data:(await T.createCustomer({auth:e.auth.props,payload:[{email:e.propsValue.email,first_name:e.propsValue.first_name,last_name:e.propsValue.last_name,company:e.propsValue.company,phone:e.propsValue.phone,notes:e.propsValue.notes}]})).data}}});var xu=V({auth:I,name:"findOrCreateProduct",displayName:"Find or Create Product",description:"Finds or creates a product",audience:"both",aiMetadata:{description:"Looks up a catalog product by exact name and returns the match if found, otherwise creates a new product from the supplied details (type, weight, and price required). Use instead of Create a Product when the item may already exist, to avoid duplicates. Idempotent: repeated calls match the same existing product by name rather than creating duplicates.",idempotent:!0},props:{name:f.ShortText({displayName:"Product Name",required:!0}),sku:f.ShortText({displayName:"SKU",required:!1}),type:f.StaticDropdown({displayName:"Product Type",required:!0,options:{options:[{label:"Physical",value:"physical"},{label:"Digital",value:"digital"}]}}),weight:f.Number({displayName:"Weight",required:!0}),price:f.Number({displayName:"Price",required:!0}),description:f.LongText({displayName:"Description",required:!1}),brand_id:f.Number({displayName:"Brand ID",description:"Brand ID",required:!1})},async run(e){let t=new URLSearchParams;t.append("name",e.propsValue.name);let r=await T.fetchProducts({auth:e.auth.props,queryString:t.toString()});return r.data&&r.data.length>0?{found:!0,data:r.data}:{found:!1,data:(await T.createProduct({auth:e.auth.props,payload:{name:e.propsValue.name,type:e.propsValue.type,sku:e.propsValue.sku,description:e.propsValue.description,weight:e.propsValue.weight,price:e.propsValue.price,brand_id:e.propsValue.brand_id}})).data}}});var _u=V({auth:I,name:"findOrCreateCustomersAddress",displayName:"Find or Create Customer\u2019s Address",description:"Finds or creates a customer\u2019s address",audience:"both",aiMetadata:{description:"For a given customer_id, looks up that customer\u2019s addresses and returns the one matching the supplied address line 1, city, and postal code if it exists, otherwise creates a new address from the supplied details. Use instead of Create Customer Address when the address may already be on file, to avoid duplicates. Idempotent: repeated calls reuse the matching address rather than appending duplicates.",idempotent:!0},props:{customer_id:ar({required:!0}),first_name:f.ShortText({displayName:"First Name",required:!0}),last_name:f.ShortText({displayName:"Last Name",required:!0}),address1:f.ShortText({displayName:"Address Line 1",required:!0}),address2:f.ShortText({displayName:"Address Line 2",required:!1}),city:f.ShortText({displayName:"City",required:!0}),state_or_province:f.ShortText({displayName:"State/Province",required:!0}),postal_code:f.ShortText({displayName:"Postal Code",required:!0}),country_code:f.ShortText({displayName:"Country Code",description:"ISO 3166-1 alpha-2 country code",required:!0}),phone:f.ShortText({displayName:"Phone",required:!1})},async run(e){let t=new URLSearchParams;t.append("customer_id:in",e.propsValue.customer_id);let r=await T.fetchCustomerAddresses({auth:e.auth.props,queryString:t.toString()});if(r.data&&r.data.length>0){let i=r.data.find(u=>u.address1===e.propsValue.address1&&u.city===e.propsValue.city&&u.postal_code===e.propsValue.postal_code);if(i)return{found:!0,data:i}}return{found:!1,data:(await T.createCustomerAddress({auth:e.auth.props,payload:[{customer_id:e.propsValue.customer_id,first_name:e.propsValue.first_name,last_name:e.propsValue.last_name,address1:e.propsValue.address1,address2:e.propsValue.address2,city:e.propsValue.city,state_or_province:e.propsValue.state_or_province,postal_code:e.propsValue.postal_code,country_code:e.propsValue.country_code,phone:e.propsValue.phone}]})).data}}});var hm=Ni({displayName:"BigCommerce",description:"BigCommerce is a leading e-commerce platform that enables businesses to create and manage online stores.",auth:I,minimumSupportedRelease:"0.36.1",logoUrl:"https://cdn.activepieces.com/pieces/bigcommerce.png",authors:["gs03-dev","sanket-a11y","Angelebeats"],actions:[iu,au,su,uu,cu,pu,lu,du,fu,gu,yu,hu,vu,xu,_u,Ws({auth:I,baseUrl:o(e=>e?or(e.props.storeHash):"","baseUrl"),authMapping:o(async e=>({"X-Auth-Token":e.props.accessToken,"Content-Type":"application/json",Accept:"application/json"}),"authMapping")})],triggers:[Gs,Ks,Js,Xs,Ys,Qs,eu,tu,ru,nu,ou]});0&&(module.exports={bigcommerce});
|
|
9
|
+
7. Save - you will get a downloaded file containing your access token and store hash`}),storeHash:f.ShortText({displayName:"Store Hash",description:"Your BigCommerce store hash (e.g., abcd1234)",required:!0}),accessToken:f.ShortText({displayName:"Access Token",description:"Your BigCommerce API access token",required:!0})},required:!0,async validate(e){try{return await T.fetchProducts({auth:e.auth}),{valid:!0}}catch{return{valid:!1,error:"Could not validate credentials. please check your credentials are correct."}}}});var ym="abandoned cart",hn=`${ym}-trigger-store-key`,hm="store/cart/abandoned",uu=J({auth:E,name:"abandonedCart",displayName:"Abandoned Cart",description:"Triggers when a cart is abandoned",aiMetadata:{description:"Fires when a shopper abandons a cart in the BigCommerce store (the cart sits inactive without checkout completing). The event identifies the affected cart; use it to drive abandoned-cart recovery flows."},props:{},sampleData:{producer:"stores/dxqdddcaklwsso",hash:"3610addd127e330084ddddd7ddd09b78abfd1a85",created_at:1761809622,store_id:"1003425529",scope:"store/cart/abandoned",data:{type:"cart",id:"ss-598f-4c95-813b-0ess950562770d"}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:hm,destination:e.webhookUrl,is_active:!0}});await e.store.put(hn,t.data.id)},async onDisable(e){let t=await e.store.get(hn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(hn)})},async run(e){return[e.payload.body]}});var vm="cart created",vn=`${vm}-trigger-store-key`,_m="store/cart/created",cu=J({auth:E,name:"cartCreated",displayName:"Cart Created",description:"Triggers when a new cart is created",aiMetadata:{description:"Fires when a new shopping cart is created in the BigCommerce store (a shopper adds the first item to a fresh cart). The event identifies the new cart."},props:{},sampleData:{producer:"stores/dxqdddcaklwsso",hash:"3610addd127e330084ddddd7ddd09b78abfd1a85",created_at:1761809622,store_id:"1003425529",scope:"store/cart/created",data:{type:"cart",id:"ss-598f-4c95-813b-0ess950562770d"}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:_m,destination:e.webhookUrl,is_active:!0}});await e.store.put(vn,t.data.id)},async onDisable(e){let t=await e.store.get(vn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(vn)})},async run(e){return[e.payload.body]}});var xm="customer address created",_n=`${xm}-trigger-store-key`,Pm="store/customer/address/created",pu=J({auth:E,name:"customerAddressCreated",displayName:"Customer Address Created",description:"Triggers when a new customer address is created",aiMetadata:{description:"Fires when a new address is added to a customer in the BigCommerce store. The event identifies the affected customer."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/customer/address/created",data:{type:"customer",id:2}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:Pm,destination:e.webhookUrl,is_active:!0}});await e.store.put(_n,t.data.id)},async onDisable(e){let t=await e.store.get(_n);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(_n)})},async run(e){return[e.payload.body]}});var bm="customer address updated",xn=`${bm}-trigger-store-key`,Tm="store/customer/address/updated",lu=J({auth:E,name:"customerAddressUpdated",displayName:"Customer Address Updated",description:"Triggers when a new customer address is updated",aiMetadata:{description:"Fires when an existing customer address is updated in the BigCommerce store. The event identifies the affected customer."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/customer/address/updated",data:{type:"customer",id:2}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:Tm,destination:e.webhookUrl,is_active:!0}});await e.store.put(xn,t.data.id)},async onDisable(e){let t=await e.store.get(xn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(xn)})},async run(e){return[e.payload.body]}});var Im="customer created",Pn=`${Im}-trigger-store-key`,Em="store/customer/created",du=J({auth:E,name:"customerCreated",displayName:"Customer Created",description:"Triggers when a new customer is created",aiMetadata:{description:"Fires when a new customer is created in the BigCommerce store. The event identifies the new customer."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/customer/created",data:{type:"customer",id:2,origin_channel_id:1,channel_ids:[1]}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:Em,destination:e.webhookUrl,is_active:!0}});await e.store.put(Pn,t.data.id)},async onDisable(e){let t=await e.store.get(Pn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(Pn)})},async run(e){return[e.payload.body]}});var Sm="customer updated",bn=`${Sm}-trigger-store-key`,Am="store/customer/updated",mu=J({auth:E,name:"customerUpdated",displayName:"Customer Updated",description:"Triggers when a customer is updated",aiMetadata:{description:"Fires when an existing customer record is updated in the BigCommerce store. The event identifies the affected customer."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/customer/updated",data:{type:"customer",id:2}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:Am,destination:e.webhookUrl,is_active:!0}});await e.store.put(bn,t.data.id)},async onDisable(e){let t=await e.store.get(bn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(bn)})},async run(e){return[e.payload.body]}});var $m="order created",Tn=`${$m}-trigger-store-key`,zm="store/order/created",fu=J({auth:E,name:"orderCreated",displayName:"Order Created",description:"Triggers when a new order is created",aiMetadata:{description:"Fires when a new order is created in the BigCommerce store. The event identifies the new order; pair with Get Order to fetch its full details."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/order/created",data:{type:"order",id:2}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:zm,destination:e.webhookUrl,is_active:!0}});await e.store.put(Tn,t.data.id)},async onDisable(e){let t=await e.store.get(Tn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(Tn)})},async run(e){return[e.payload.body]}});var wm="order updated",In=`${wm}-trigger-store-key`,Om="store/order/updated",gu=J({auth:E,name:"orderUpdated",displayName:"Order Updated",description:"Triggers when an order is updated",aiMetadata:{description:"Fires when an existing order is updated in the BigCommerce store (any change to the order, not just its status). The event identifies the affected order; pair with Get Order for full details."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/order/updated",data:{type:"order",id:2}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:Om,destination:e.webhookUrl,is_active:!0}});await e.store.put(In,t.data.id)},async onDisable(e){let t=await e.store.get(In);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(In)})},async run(e){return[e.payload.body]}});var km="order status updated",En=`${km}-trigger-store-key`,Rm="store/order/statusUpdated",yu=J({auth:E,name:"orderStatusUpdated",displayName:"Order Status Updated",description:"Triggers when an order status has changed",aiMetadata:{description:"Fires specifically when an order\u2019s status changes in the BigCommerce store (e.g. moves to shipped or completed). Use this instead of Order Updated when you only care about status transitions. The event identifies the affected order."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/order/statusUpdated",data:{type:"order",id:2}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:Rm,destination:e.webhookUrl,is_active:!0}});await e.store.put(En,t.data.id)},async onDisable(e){let t=await e.store.get(En);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(En)})},async run(e){return[e.payload.body]}});var Nm="product created",Sn=`${Nm}-trigger-store-key`,Cm="store/product/created",hu=J({auth:E,name:"productCreated",displayName:"Product Created",description:"Triggers when a new product is created",aiMetadata:{description:"Fires when a new product is added to the BigCommerce store catalog. The event identifies the new product."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"c6db17090e98d2c58c0cb1988b5e9ace48215e22",created_at:1761808831,store_id:"1003425529",scope:"store/product/created",data:{type:"product",id:113}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:Cm,destination:e.webhookUrl,is_active:!0}});await e.store.put(Sn,t.data.id)},async onDisable(e){let t=await e.store.get(Sn);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(Sn)})},async run(e){return[e.payload.body]}});var Dm="shipment created",An=`${Dm}-trigger-store-key`,Um="store/shipment/created",vu=J({auth:E,name:"shipmentCreated",displayName:"Shipment Created",description:"Triggers when a new shipment is created",aiMetadata:{description:"Fires when a new shipment is created for an order in the BigCommerce store (items are shipped/fulfilled). The event identifies the new shipment."},props:{},sampleData:{producer:"stores/xqcaklwsso",hash:"d7b899890f5e0e98a3e074f018b14b07d5d89360",created_at:1761808595,store_id:"1003425529",scope:"store/shipment/created",data:{type:"shipment",id:2}},type:"WEBHOOK",async onEnable(e){let t=await T.createWebhook({auth:e.auth.props,payload:{scope:Um,destination:e.webhookUrl,is_active:!0}});await e.store.put(An,t.data.id)},async onDisable(e){let t=await e.store.get(An);t&&await T.deleteWebhook({auth:e.auth.props,webhookId:t}).then(async()=>{await e.store.delete(An)})},async run(e){return[e.payload.body]}});var _u=V({auth:E,name:"createCustomer",displayName:"Create Customer",description:"Creates a customer",audience:"both",aiMetadata:{description:"Creates a new customer record in a BigCommerce store from an email plus first/last name (company, phone, and notes optional). Use to register a shopper or contact. Not idempotent: each call adds a new customer, and BigCommerce rejects a duplicate email rather than returning the existing one, so call Search Customer or Find or Create Customer first if the customer may already exist.",idempotent:!1},props:{email:f.ShortText({displayName:"Email",description:"Customer email address",required:!0}),first_name:f.ShortText({displayName:"First Name",description:"Customer first name",required:!0}),last_name:f.ShortText({displayName:"Last Name",description:"Customer last name",required:!0}),company:f.ShortText({displayName:"Company",description:"Customer company name",required:!1}),phone:f.ShortText({displayName:"Phone",description:"Customer phone number",required:!1}),notes:f.LongText({displayName:"Notes",description:"Customer notes",required:!1})},async run(e){return await T.createCustomer({auth:e.auth.props,payload:[{email:e.propsValue.email,first_name:e.propsValue.first_name,last_name:e.propsValue.last_name,company:e.propsValue.company,phone:e.propsValue.phone,notes:e.propsValue.notes}]})}});var xu=V({auth:E,name:"createAProduct",displayName:"Create a Product",description:"Creates a Product",audience:"both",aiMetadata:{description:"Creates a new catalog product in a BigCommerce store. Use to add an item to the store. Requires name, type (physical or digital), weight, and price; SKU, description, and brand_id are optional. Not idempotent: each call adds a new product, so search the catalog first if it may already exist.",idempotent:!1},props:{name:f.ShortText({displayName:"Product Name",description:"Name of the product",required:!0}),type:f.StaticDropdown({displayName:"Product Type",description:"Type of product",required:!0,options:{options:[{label:"Physical",value:"physical"},{label:"Digital",value:"digital"}]}}),sku:f.ShortText({displayName:"SKU",description:"Product SKU",required:!1}),description:f.LongText({displayName:"Description",description:"Product description",required:!1}),weight:f.Number({displayName:"Weight",description:"Product weight",required:!0}),price:f.Number({displayName:"Price",description:"Product price",required:!0}),brand_id:f.Number({displayName:"Brand ID",description:"Brand ID",required:!1})},async run(e){return await T.createProduct({auth:e.auth.props,payload:{name:e.propsValue.name,type:e.propsValue.type,sku:e.propsValue.sku,description:e.propsValue.description,weight:e.propsValue.weight,price:e.propsValue.price,brand_id:e.propsValue.brand_id}})}});var Pu=V({auth:E,name:"updateAProduct",displayName:"Update a Product",description:"Updates an existing Product",audience:"both",aiMetadata:{description:"Updates an existing catalog product in a BigCommerce store, identified by its productId. Only the fields you supply are sent (null/undefined values are dropped so existing data is preserved), so use it for partial edits to name, type, SKU, description, weight, price, or brand. Idempotent: re-applying the same field values leaves the product in the same state.",idempotent:!0},props:{productId:f.ShortText({displayName:"Product ID",description:"The ID of the product to update",required:!0}),name:f.ShortText({displayName:"Product Name",description:"Name of the product",required:!1}),type:f.StaticDropdown({displayName:"Product Type",description:"Type of product",required:!1,options:{options:[{label:"Physical",value:"physical"},{label:"Digital",value:"digital"}]}}),sku:f.ShortText({displayName:"SKU",description:"Product SKU",required:!1}),description:f.LongText({displayName:"Description",description:"Product description",required:!1}),weight:f.Number({displayName:"Weight",description:"Product weight",required:!1}),price:f.Number({displayName:"Price",description:"Product price",required:!1}),brand_id:f.Number({displayName:"Brand ID",description:"Brand ID",required:!1})},async run(e){let{productId:t,...r}=e.propsValue,n=Object.fromEntries(Object.entries(r).filter(([i,u])=>u!=null));return await T.updateProduct({auth:e.auth.props,productId:t,payload:n})}});var bu=V({auth:E,name:"deleteAProduct",displayName:"Delete a Product",description:"Deletes an existing Product",audience:"both",aiMetadata:{description:"Permanently deletes a catalog product from a BigCommerce store by its productId. Use to remove an item from the store. This is destructive and cannot be undone. Effectively idempotent: deleting an already-removed product has no further effect, though the call may error if the id no longer exists.",idempotent:!0},props:{productId:f.ShortText({displayName:"Product ID",description:"The ID of the product to delete",required:!0})},async run(e){return await T.deleteProduct({auth:e.auth.props,productId:e.propsValue.productId})}});var Tu=V({auth:E,name:"getOrder",displayName:"Get Order",description:"Gets details of an order",audience:"both",aiMetadata:{description:"Retrieves the full details of a single BigCommerce order by its orderId. Use when you already have an order id (e.g. from an order trigger or List Orders) and need its data. Idempotent read-only lookup with no side effects.",idempotent:!0},props:{orderId:f.ShortText({displayName:"Order ID",description:"The ID of the order to retrieve",required:!0})},async run(e){return await T.fetchOrder({auth:e.auth.props,orderId:e.propsValue.orderId})}});var Iu=V({auth:E,name:"listOrders",displayName:"List Orders",description:"Lists all orders",audience:"both",aiMetadata:{description:"Lists orders from a BigCommerce store. With no filters it returns all orders; optionally narrow by customer_id and/or status_id to a subset. Use to browse or find orders when you do not have a specific order id. Idempotent read-only query with no side effects.",idempotent:!0},props:{customer_id:f.Number({displayName:"Customer ID",description:"Filter by customer ID",required:!1}),status_id:f.Number({displayName:"Status ID",description:"Filter by status ID",required:!1})},async run(e){let t=new URLSearchParams;return e.propsValue.customer_id!==void 0&&e.propsValue.customer_id!==null&&t.append("customer_id",e.propsValue.customer_id.toString()),e.propsValue.status_id!==void 0&&e.propsValue.status_id!==null&&t.append("status_id",e.propsValue.status_id.toString()),await T.fetchOrders({auth:e.auth.props,queryString:t.toString()})}});var Eu=V({auth:E,name:"listCategories",displayName:"List Categories",description:"Lists all categories",audience:"both",aiMetadata:{description:"Lists product categories from a BigCommerce store. With no name filter it returns all categories; provide a name to filter to matching categories. Use to discover category names or ids before assigning products. Idempotent read-only query with no side effects.",idempotent:!0},props:{name:f.ShortText({displayName:"Category Name",description:"Filter by category name",required:!1})},async run(e){let t=new URLSearchParams;return e.propsValue.name&&t.append("name",e.propsValue.name),await T.fetchCategories({auth:e.auth.props,queryString:t.toString()})}});var Su=V({auth:E,name:"createBlogPost",displayName:"Create Blog Post",description:"Creates a blog post",audience:"both",aiMetadata:{description:"Creates a blog post in a BigCommerce store's blog. Requires a title and body (HTML supported); author, URL, published date, meta description/keywords, tags, and a published flag are optional. Use to publish store blog content. Not idempotent: each call creates a new post.",idempotent:!1},props:{title:f.ShortText({displayName:"Title",description:"Blog post title",required:!0}),body:f.LongText({displayName:"Body",description:"Blog post content (HTML supported)",required:!0}),author:f.ShortText({displayName:"Author",description:"Author name",required:!1}),url:f.ShortText({displayName:"URL",description:"URL for the public blog post. Example - /blog/welcome-bigcommerce/",required:!1}),published_date:f.DateTime({displayName:"Published Date",description:"Published Date for the blog post. Example - Wed, 10 Aug 2022 15:39:15 -0500",required:!1}),meta_description:f.LongText({displayName:"Meta Description",description:"Description text for this blog post\u2019s <meta/> element.",required:!1}),meta_keywords:f.LongText({displayName:"Meta Keywords",description:"Comma seperated (,) Keywords for this blog post\u2019s <meta/> element. Eg welcome, bigcommerce",required:!1}),tags:f.Array({displayName:"Tags",description:"Array of tags",required:!1}),is_published:f.Checkbox({displayName:"Is Published",description:"Whether the post is published",required:!1,defaultValue:!0})},async run(e){return await T.createBlogPost({auth:e.auth.props,payload:{title:e.propsValue.title,body:e.propsValue.body,author:e.propsValue.author,tags:e.propsValue.tags,is_published:e.propsValue.is_published,meta_description:e.propsValue.meta_description,meta_keywords:e.propsValue.meta_keywords,published_date:e.propsValue.published_date,url:e.propsValue.url}})}});var cr=o(({required:e})=>f.Dropdown({auth:E,displayName:"Customer",description:"Select the customer",required:e,refreshers:["auth"],options:o(async({auth:t})=>{if(!t)return Ue("Please connect your account first");try{let r=await T.fetchCustomers({auth:t.props}),n=Array.isArray(r?.data)?r.data:[];return n.length===0?Ue("No customers found"):{disabled:!1,options:n.map(u=>({label:[u.first_name,u.last_name].filter(p=>typeof p=="string"&&p.trim()!=="").join(" ")||u.email||u.id,value:u.id}))}}catch{return Ue("Failed to load customers")}},"options")}),"customerDropdown"),Au=o(({required:e})=>f.MultiSelectDropdown({auth:E,displayName:"Customers",description:"Select the customers",required:e,refreshers:["auth"],options:o(async({auth:t})=>{if(!t)return Ue("Please connect your account first");try{let r=await T.fetchCustomers({auth:t.props}),n=Array.isArray(r?.data)?r.data:[];return n.length===0?Ue("No customers found"):{disabled:!1,options:n.map(u=>({label:[u.first_name,u.last_name].filter(p=>typeof p=="string"&&p.trim()!=="").join(" ")||u.email||u.id,value:u.id}))}}catch{return Ue("Failed to load customers")}},"options")}),"multiCustomerDropdown");var $u=V({auth:E,name:"createCustomerAddress",displayName:"Create Customer Address",description:"Creates a customer's address",audience:"both",aiMetadata:{description:"Adds a new address to an existing BigCommerce customer, identified by customer_id (selected from a dropdown of store customers). Requires name, address line 1, city, state/province, postal code, and an ISO 3166-1 alpha-2 country code. Use to attach a shipping or billing address to a customer. Not idempotent: each call appends a new address even if an identical one exists, so use Find or Create Customer\u2019s Address to avoid duplicates.",idempotent:!1},props:{customer_id:cr({required:!0}),first_name:f.ShortText({displayName:"First Name",required:!0}),last_name:f.ShortText({displayName:"Last Name",required:!0}),address1:f.ShortText({displayName:"Address Line 1",required:!0}),address2:f.ShortText({displayName:"Address Line 2",required:!1}),city:f.ShortText({displayName:"City",required:!0}),state_or_province:f.ShortText({displayName:"State/Province",required:!0}),postal_code:f.ShortText({displayName:"Postal Code",required:!0}),country_code:f.ShortText({displayName:"Country Code",description:"ISO 3166-1 alpha-2 country code",required:!0}),phone:f.ShortText({displayName:"Phone",required:!1})},async run(e){return await T.createCustomerAddress({auth:e.auth.props,payload:[{customer_id:e.propsValue.customer_id,first_name:e.propsValue.first_name,last_name:e.propsValue.last_name,address1:e.propsValue.address1,address2:e.propsValue.address2,city:e.propsValue.city,state_or_province:e.propsValue.state_or_province,postal_code:e.propsValue.postal_code,country_code:e.propsValue.country_code,phone:e.propsValue.phone}]})}});var zu=V({auth:E,name:"searchCustomer",displayName:"Search Customer",description:"Searches for a registered customer",audience:"both",aiMetadata:{description:"Searches registered customers in a BigCommerce store by email, phone, and/or name. With no filters it returns all customers; supplying any filter narrows to matches. Use to look up a customer or check whether one exists before creating it. Idempotent read-only query with no side effects.",idempotent:!0},props:{email:f.ShortText({displayName:"Email",description:"Customer email to search for",required:!1}),phone:f.ShortText({displayName:"Phone Number",description:"Phone Number to search for",required:!1}),name:f.ShortText({displayName:"Name",description:"Customer name to search for",required:!1})},async run(e){let t=new URLSearchParams;return e.propsValue.email&&t.append("email:in",e.propsValue.email),e.propsValue.name&&t.append("name:in",`${e.propsValue.name}`),e.propsValue.phone&&t.append("phone:in",e.propsValue.phone),await T.fetchCustomers({auth:e.auth.props,queryString:t.toString()})}});var wu=V({auth:E,name:"searchProduct",displayName:"Search Product",description:"Searches for a product in the catalog",audience:"both",aiMetadata:{description:"Searches the BigCommerce product catalog by name, SKU, type, brand, weight, and/or price. With no filters it returns all products; supplying any filter narrows to matches. Use to find a product or its id, or to check whether one exists before creating it. Idempotent read-only query with no side effects.",idempotent:!0},props:{name:f.ShortText({displayName:"Product Name",description:"Product name to search for",required:!1}),sku:f.ShortText({displayName:"SKU",description:"Product SKU to search for",required:!1}),type:f.StaticDropdown({displayName:"Product Type",required:!1,options:{options:[{label:"Physical",value:"physical"},{label:"Digital",value:"digital"}]}}),brand_id:f.ShortText({displayName:"Brand ID",description:"Brand ID to search for",required:!1}),weight:f.Number({displayName:"Weight",required:!1}),price:f.Number({displayName:"Price",required:!1})},async run(e){let t=new URLSearchParams;return e.propsValue.name&&t.append("name",e.propsValue.name),e.propsValue.sku&&t.append("sku",e.propsValue.sku),e.propsValue.brand_id&&t.append("brand_id",e.propsValue.brand_id),e.propsValue.type&&t.append("type",e.propsValue.type),e.propsValue.price&&t.append("price",String(e.propsValue.price)),e.propsValue.weight&&t.append("weight",String(e.propsValue.weight)),await T.fetchProducts({auth:e.auth.props,queryString:t.toString()})}});var Ou=V({auth:E,name:"searchCustomerAddress",displayName:"Search Customer Address",description:"Searches for a customer\u2019s address",audience:"both",aiMetadata:{description:"Searches customer addresses in a BigCommerce store, optionally filtered by one or more customer ids and/or a name. With no filters it returns all addresses; supplying filters narrows to matches. Use to look up addresses belonging to specific customers. Idempotent read-only query with no side effects.",idempotent:!0},props:{customer_ids:Au({required:!1}),name:f.ShortText({displayName:"Name",description:"Customer name to search for",required:!1})},async run(e){let t=new URLSearchParams;return e.propsValue.customer_ids&&t.append("customer_ids:in",e.propsValue.customer_ids.join(",")),e.propsValue.name&&t.append("name:in",`${e.propsValue.name}`),await T.fetchCustomerAddresses({auth:e.auth.props,queryString:t.toString()})}});var ku=V({auth:E,name:"findOrCreateCustomer",displayName:"Find or Create Customer",description:"Finds or creates a customer",audience:"both",aiMetadata:{description:"Looks up a BigCommerce customer by email (and phone if given) and returns the match if found, otherwise creates a new customer from the supplied details. Use this instead of Create Customer when the customer may already exist, to avoid duplicate-email errors. Idempotent: repeated calls match the same existing record rather than creating duplicates.",idempotent:!0},props:{email:f.ShortText({displayName:"Email",description:"Customer email address",required:!0}),first_name:f.ShortText({displayName:"First Name",description:"Customer first name",required:!0}),last_name:f.ShortText({displayName:"Last Name",description:"Customer last name",required:!0}),company:f.ShortText({displayName:"Company",description:"Customer company name",required:!1}),phone:f.ShortText({displayName:"Phone",description:"Customer phone number",required:!1}),notes:f.LongText({displayName:"Notes",description:"Customer notes",required:!1})},async run(e){let t=new URLSearchParams;t.append("email:in",e.propsValue.email),e.propsValue.phone&&t.append("phone:in",e.propsValue.phone);let r=await T.fetchCustomers({auth:e.auth.props,queryString:t.toString()});return r.data&&r.data.length>0?{found:!0,data:r.data}:{found:!1,data:(await T.createCustomer({auth:e.auth.props,payload:[{email:e.propsValue.email,first_name:e.propsValue.first_name,last_name:e.propsValue.last_name,company:e.propsValue.company,phone:e.propsValue.phone,notes:e.propsValue.notes}]})).data}}});var Ru=V({auth:E,name:"findOrCreateProduct",displayName:"Find or Create Product",description:"Finds or creates a product",audience:"both",aiMetadata:{description:"Looks up a catalog product by exact name and returns the match if found, otherwise creates a new product from the supplied details (type, weight, and price required). Use instead of Create a Product when the item may already exist, to avoid duplicates. Idempotent: repeated calls match the same existing product by name rather than creating duplicates.",idempotent:!0},props:{name:f.ShortText({displayName:"Product Name",required:!0}),sku:f.ShortText({displayName:"SKU",required:!1}),type:f.StaticDropdown({displayName:"Product Type",required:!0,options:{options:[{label:"Physical",value:"physical"},{label:"Digital",value:"digital"}]}}),weight:f.Number({displayName:"Weight",required:!0}),price:f.Number({displayName:"Price",required:!0}),description:f.LongText({displayName:"Description",required:!1}),brand_id:f.Number({displayName:"Brand ID",description:"Brand ID",required:!1})},async run(e){let t=new URLSearchParams;t.append("name",e.propsValue.name);let r=await T.fetchProducts({auth:e.auth.props,queryString:t.toString()});return r.data&&r.data.length>0?{found:!0,data:r.data}:{found:!1,data:(await T.createProduct({auth:e.auth.props,payload:{name:e.propsValue.name,type:e.propsValue.type,sku:e.propsValue.sku,description:e.propsValue.description,weight:e.propsValue.weight,price:e.propsValue.price,brand_id:e.propsValue.brand_id}})).data}}});var Nu=V({auth:E,name:"findOrCreateCustomersAddress",displayName:"Find or Create Customer\u2019s Address",description:"Finds or creates a customer\u2019s address",audience:"both",aiMetadata:{description:"For a given customer_id, looks up that customer\u2019s addresses and returns the one matching the supplied address line 1, city, and postal code if it exists, otherwise creates a new address from the supplied details. Use instead of Create Customer Address when the address may already be on file, to avoid duplicates. Idempotent: repeated calls reuse the matching address rather than appending duplicates.",idempotent:!0},props:{customer_id:cr({required:!0}),first_name:f.ShortText({displayName:"First Name",required:!0}),last_name:f.ShortText({displayName:"Last Name",required:!0}),address1:f.ShortText({displayName:"Address Line 1",required:!0}),address2:f.ShortText({displayName:"Address Line 2",required:!1}),city:f.ShortText({displayName:"City",required:!0}),state_or_province:f.ShortText({displayName:"State/Province",required:!0}),postal_code:f.ShortText({displayName:"Postal Code",required:!0}),country_code:f.ShortText({displayName:"Country Code",description:"ISO 3166-1 alpha-2 country code",required:!0}),phone:f.ShortText({displayName:"Phone",required:!1})},async run(e){let t=new URLSearchParams;t.append("customer_id:in",e.propsValue.customer_id);let r=await T.fetchCustomerAddresses({auth:e.auth.props,queryString:t.toString()});if(r.data&&r.data.length>0){let i=r.data.find(u=>u.address1===e.propsValue.address1&&u.city===e.propsValue.city&&u.postal_code===e.propsValue.postal_code);if(i)return{found:!0,data:i}}return{found:!1,data:(await T.createCustomerAddress({auth:e.auth.props,payload:[{customer_id:e.propsValue.customer_id,first_name:e.propsValue.first_name,last_name:e.propsValue.last_name,address1:e.propsValue.address1,address2:e.propsValue.address2,city:e.propsValue.city,state_or_province:e.propsValue.state_or_province,postal_code:e.propsValue.postal_code,country_code:e.propsValue.country_code,phone:e.propsValue.phone}]})).data}}});var Mm=Hi({displayName:"BigCommerce",description:"BigCommerce is a leading e-commerce platform that enables businesses to create and manage online stores.",auth:E,minimumSupportedRelease:"0.36.1",logoUrl:"https://cdn.activepieces.com/pieces/bigcommerce.png",authors:["gs03-dev","sanket-a11y","Angelebeats"],actions:[_u,xu,Pu,bu,Tu,Iu,Eu,Su,$u,zu,wu,Ou,ku,Ru,Nu,su({auth:E,baseUrl:o(e=>e?sr(e.props.storeHash):"","baseUrl"),authMapping:o(async e=>({"X-Auth-Token":e.props.accessToken,"Content-Type":"application/json",Accept:"application/json"}),"authMapping")})],triggers:[uu,cu,pu,lu,du,mu,fu,gu,yu,hu,vu]});0&&(module.exports={bigcommerce});
|
|
10
10
|
/*! Bundled license information:
|
|
11
11
|
|
|
12
12
|
mime-types/index.js:
|