@superglue/cli 1.1.152 → 1.1.154
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/.claude-plugin/plugin.json +1 -1
- package/dist/cli.js +3 -3
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "superglue",
|
|
3
3
|
"description": "Build, test, and manage superglue tools via the sg CLI. Use when working with superglue tools, systems, APIs, SDKs, or the sg command.",
|
|
4
|
-
"version": "1.1.
|
|
4
|
+
"version": "1.1.154",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "superglue",
|
|
7
7
|
"email": "hello@superglue.cloud"
|
package/dist/cli.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
"use strict";var BY=Object.create;var jA=Object.defineProperty;var wY=Object.getOwnPropertyDescriptor;var QY=Object.getOwnPropertyNames;var vY=Object.getPrototypeOf,_Y=Object.prototype.hasOwnProperty;var He=(t,e)=>()=>(t&&(e=t(t=0)),e);var g=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Pv=(t,e)=>{for(var r in e)jA(t,r,{get:e[r],enumerable:!0})},Fv=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of QY(e))!_Y.call(t,i)&&i!==r&&jA(t,i,{get:()=>e[i],enumerable:!(n=wY(e,i))||n.enumerable});return t};var ge=(t,e,r)=>(r=t!=null?BY(vY(t)):{},Fv(e||!t||!t.__esModule?jA(r,"default",{value:t,enumerable:!0}):r,t)),eE=t=>Fv(jA({},"__esModule",{value:!0}),t);var zv=g((IRe,Hv)=>{"use strict";var $v=9007199254740991,DY="[object Arguments]",TY="[object Function]",RY="[object GeneratorFunction]",NY=/^(?:0|[1-9]\d*)$/;function kY(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}function OY(t,e){return function(r){return t(e(r))}}var qA=Object.prototype,tE=qA.hasOwnProperty,jv=qA.toString,UY=qA.propertyIsEnumerable,MY=OY(Object.keys,Object);function xY(t,e){var r=jY(t)||$Y(t)?kY(t.length,String):[],n=r.length,i=!!n;for(var o in t)(e||tE.call(t,o))&&!(i&&(o=="length"||PY(o,n)))&&r.push(o);return r}function LY(t){if(!FY(t))return MY(t);var e=[];for(var r in Object(t))tE.call(t,r)&&r!="constructor"&&e.push(r);return e}function PY(t,e){return e=e??$v,!!e&&(typeof t=="number"||NY.test(t))&&t>-1&&t%1==0&&t<e}function FY(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||qA;return t===r}function $Y(t){return qY(t)&&tE.call(t,"callee")&&(!UY.call(t,"callee")||jv.call(t)==DY)}var jY=Array.isArray;function qv(t){return t!=null&&zY(t.length)&&!HY(t)}function qY(t){return YY(t)&&qv(t)}function HY(t){var e=GY(t)?jv.call(t):"";return e==TY||e==RY}function zY(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=$v}function GY(t){var e=typeof t;return!!t&&(e=="object"||e=="function")}function YY(t){return!!t&&typeof t=="object"}function VY(t){return qv(t)?xY(t):LY(t)}Hv.exports=VY});var I_=g((ol,Ac)=>{"use strict";var JY=200,t_="__lodash_hash_undefined__",WY=800,ZY=16,r_=9007199254740991,n_="[object Arguments]",KY="[object Array]",XY="[object AsyncFunction]",eV="[object Boolean]",tV="[object Date]",rV="[object Error]",i_="[object Function]",nV="[object GeneratorFunction]",iV="[object Map]",oV="[object Number]",sV="[object Null]",o_="[object Object]",aV="[object Proxy]",cV="[object RegExp]",uV="[object Set]",lV="[object String]",dV="[object Undefined]",AV="[object WeakMap]",pV="[object ArrayBuffer]",fV="[object DataView]",hV="[object Float32Array]",gV="[object Float64Array]",mV="[object Int8Array]",yV="[object Int16Array]",EV="[object Int32Array]",IV="[object Uint8Array]",CV="[object Uint8ClampedArray]",bV="[object Uint16Array]",SV="[object Uint32Array]",BV=/[\\^$.*+?()[\]{}|]/g,wV=/^\[object .+?Constructor\]$/,QV=/^(?:0|[1-9]\d*)$/,Ve={};Ve[hV]=Ve[gV]=Ve[mV]=Ve[yV]=Ve[EV]=Ve[IV]=Ve[CV]=Ve[bV]=Ve[SV]=!0;Ve[n_]=Ve[KY]=Ve[pV]=Ve[eV]=Ve[fV]=Ve[tV]=Ve[rV]=Ve[i_]=Ve[iV]=Ve[oV]=Ve[o_]=Ve[cV]=Ve[uV]=Ve[lV]=Ve[AV]=!1;var s_=typeof global=="object"&&global&&global.Object===Object&&global,vV=typeof self=="object"&&self&&self.Object===Object&&self,cl=s_||vV||Function("return this")(),a_=typeof ol=="object"&&ol&&!ol.nodeType&&ol,sl=a_&&typeof Ac=="object"&&Ac&&!Ac.nodeType&&Ac,c_=sl&&sl.exports===a_,rE=c_&&s_.process,Gv=(function(){try{var t=sl&&sl.require&&sl.require("util").types;return t||rE&&rE.binding&&rE.binding("util")}catch{}})(),Yv=Gv&&Gv.isTypedArray;function _V(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}function DV(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}function TV(t){return function(e){return t(e)}}function RV(t,e){return t?.[e]}function NV(t,e){return function(r){return t(e(r))}}var kV=Array.prototype,OV=Function.prototype,GA=Object.prototype,nE=cl["__core-js_shared__"],YA=OV.toString,go=GA.hasOwnProperty,Vv=(function(){var t=/[^.]+$/.exec(nE&&nE.keys&&nE.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})(),u_=GA.toString,UV=YA.call(Object),MV=RegExp("^"+YA.call(go).replace(BV,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),HA=c_?cl.Buffer:void 0,Jv=cl.Symbol,Wv=cl.Uint8Array,Zv=HA?HA.allocUnsafe:void 0,l_=NV(Object.getPrototypeOf,Object),Kv=Object.create,xV=GA.propertyIsEnumerable,LV=kV.splice,ta=Jv?Jv.toStringTag:void 0,zA=(function(){try{var t=uE(Object,"defineProperty");return t({},"",{}),t}catch{}})(),PV=HA?HA.isBuffer:void 0,Xv=Math.max,FV=Date.now,d_=uE(cl,"Map"),al=uE(Object,"create"),$V=(function(){function t(){}return function(e){if(!na(e))return{};if(Kv)return Kv(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}})();function ra(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function jV(){this.__data__=al?al(null):{},this.size=0}function qV(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}function HV(t){var e=this.__data__;if(al){var r=e[t];return r===t_?void 0:r}return go.call(e,t)?e[t]:void 0}function zV(t){var e=this.__data__;return al?e[t]!==void 0:go.call(e,t)}function GV(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=al&&e===void 0?t_:e,this}ra.prototype.clear=jV;ra.prototype.delete=qV;ra.prototype.get=HV;ra.prototype.has=zV;ra.prototype.set=GV;function mo(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function YV(){this.__data__=[],this.size=0}function VV(t){var e=this.__data__,r=VA(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():LV.call(e,r,1),--this.size,!0}function JV(t){var e=this.__data__,r=VA(e,t);return r<0?void 0:e[r][1]}function WV(t){return VA(this.__data__,t)>-1}function ZV(t,e){var r=this.__data__,n=VA(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}mo.prototype.clear=YV;mo.prototype.delete=VV;mo.prototype.get=JV;mo.prototype.has=WV;mo.prototype.set=ZV;function pc(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function KV(){this.size=0,this.__data__={hash:new ra,map:new(d_||mo),string:new ra}}function XV(t){var e=WA(this,t).delete(t);return this.size-=e?1:0,e}function eJ(t){return WA(this,t).get(t)}function tJ(t){return WA(this,t).has(t)}function rJ(t,e){var r=WA(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}pc.prototype.clear=KV;pc.prototype.delete=XV;pc.prototype.get=eJ;pc.prototype.has=tJ;pc.prototype.set=rJ;function fc(t){var e=this.__data__=new mo(t);this.size=e.size}function nJ(){this.__data__=new mo,this.size=0}function iJ(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}function oJ(t){return this.__data__.get(t)}function sJ(t){return this.__data__.has(t)}function aJ(t,e){var r=this.__data__;if(r instanceof mo){var n=r.__data__;if(!d_||n.length<JY-1)return n.push([t,e]),this.size=++r.size,this;r=this.__data__=new pc(n)}return r.set(t,e),this.size=r.size,this}fc.prototype.clear=nJ;fc.prototype.delete=iJ;fc.prototype.get=oJ;fc.prototype.has=sJ;fc.prototype.set=aJ;function cJ(t,e){var r=aE(t),n=!r&&sE(t),i=!r&&!n&&h_(t),o=!r&&!n&&!i&&m_(t),s=r||n||i||o,a=s?DV(t.length,String):[],c=a.length;for(var u in t)(e||go.call(t,u))&&!(s&&(u=="length"||i&&(u=="offset"||u=="parent")||o&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||p_(u,c)))&&a.push(u);return a}function iE(t,e,r){(r!==void 0&&!ZA(t[e],r)||r===void 0&&!(e in t))&&cE(t,e,r)}function uJ(t,e,r){var n=t[e];(!(go.call(t,e)&&ZA(n,r))||r===void 0&&!(e in t))&&cE(t,e,r)}function VA(t,e){for(var r=t.length;r--;)if(ZA(t[r][0],e))return r;return-1}function cE(t,e,r){e=="__proto__"&&zA?zA(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}var lJ=SJ();function JA(t){return t==null?t===void 0?dV:sV:ta&&ta in Object(t)?BJ(t):TJ(t)}function e_(t){return ul(t)&&JA(t)==n_}function dJ(t){if(!na(t)||_J(t))return!1;var e=dE(t)?MV:wV;return e.test(OJ(t))}function AJ(t){return ul(t)&&g_(t.length)&&!!Ve[JA(t)]}function pJ(t){if(!na(t))return DJ(t);var e=f_(t),r=[];for(var n in t)n=="constructor"&&(e||!go.call(t,n))||r.push(n);return r}function A_(t,e,r,n,i){t!==e&&lJ(e,function(o,s){if(i||(i=new fc),na(o))fJ(t,e,s,r,A_,n,i);else{var a=n?n(oE(t,s),o,s+"",t,e,i):void 0;a===void 0&&(a=o),iE(t,s,a)}},y_)}function fJ(t,e,r,n,i,o,s){var a=oE(t,r),c=oE(e,r),u=s.get(c);if(u){iE(t,r,u);return}var l=o?o(a,c,r+"",t,e,s):void 0,d=l===void 0;if(d){var A=aE(c),p=!A&&h_(c),h=!A&&!p&&m_(c);l=c,A||p||h?aE(a)?l=a:UJ(a)?l=IJ(a):p?(d=!1,l=mJ(c,!0)):h?(d=!1,l=EJ(c,!0)):l=[]:MJ(c)||sE(c)?(l=a,sE(a)?l=xJ(a):(!na(a)||dE(a))&&(l=wJ(c))):d=!1}d&&(s.set(c,l),i(l,c,n,o,s),s.delete(c)),iE(t,r,l)}function hJ(t,e){return NJ(RJ(t,e,E_),t+"")}var gJ=zA?function(t,e){return zA(t,"toString",{configurable:!0,enumerable:!1,value:PJ(e),writable:!0})}:E_;function mJ(t,e){if(e)return t.slice();var r=t.length,n=Zv?Zv(r):new t.constructor(r);return t.copy(n),n}function yJ(t){var e=new t.constructor(t.byteLength);return new Wv(e).set(new Wv(t)),e}function EJ(t,e){var r=e?yJ(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}function IJ(t,e){var r=-1,n=t.length;for(e||(e=Array(n));++r<n;)e[r]=t[r];return e}function CJ(t,e,r,n){var i=!r;r||(r={});for(var o=-1,s=e.length;++o<s;){var a=e[o],c=n?n(r[a],t[a],a,r,t):void 0;c===void 0&&(c=t[a]),i?cE(r,a,c):uJ(r,a,c)}return r}function bJ(t){return hJ(function(e,r){var n=-1,i=r.length,o=i>1?r[i-1]:void 0,s=i>2?r[2]:void 0;for(o=t.length>3&&typeof o=="function"?(i--,o):void 0,s&&QJ(r[0],r[1],s)&&(o=i<3?void 0:o,i=1),e=Object(e);++n<i;){var a=r[n];a&&t(e,a,n,o)}return e})}function SJ(t){return function(e,r,n){for(var i=-1,o=Object(e),s=n(e),a=s.length;a--;){var c=s[t?a:++i];if(r(o[c],c,o)===!1)break}return e}}function WA(t,e){var r=t.__data__;return vJ(e)?r[typeof e=="string"?"string":"hash"]:r.map}function uE(t,e){var r=RV(t,e);return dJ(r)?r:void 0}function BJ(t){var e=go.call(t,ta),r=t[ta];try{t[ta]=void 0;var n=!0}catch{}var i=u_.call(t);return n&&(e?t[ta]=r:delete t[ta]),i}function wJ(t){return typeof t.constructor=="function"&&!f_(t)?$V(l_(t)):{}}function p_(t,e){var r=typeof t;return e=e??r_,!!e&&(r=="number"||r!="symbol"&&QV.test(t))&&t>-1&&t%1==0&&t<e}function QJ(t,e,r){if(!na(r))return!1;var n=typeof e;return(n=="number"?lE(r)&&p_(e,r.length):n=="string"&&e in r)?ZA(r[e],t):!1}function vJ(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}function _J(t){return!!Vv&&Vv in t}function f_(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||GA;return t===r}function DJ(t){var e=[];if(t!=null)for(var r in Object(t))e.push(r);return e}function TJ(t){return u_.call(t)}function RJ(t,e,r){return e=Xv(e===void 0?t.length-1:e,0),function(){for(var n=arguments,i=-1,o=Xv(n.length-e,0),s=Array(o);++i<o;)s[i]=n[e+i];i=-1;for(var a=Array(e+1);++i<e;)a[i]=n[i];return a[e]=r(s),_V(t,this,a)}}function oE(t,e){if(!(e==="constructor"&&typeof t[e]=="function")&&e!="__proto__")return t[e]}var NJ=kJ(gJ);function kJ(t){var e=0,r=0;return function(){var n=FV(),i=ZY-(n-r);if(r=n,i>0){if(++e>=WY)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}function OJ(t){if(t!=null){try{return YA.call(t)}catch{}try{return t+""}catch{}}return""}function ZA(t,e){return t===e||t!==t&&e!==e}var sE=e_((function(){return arguments})())?e_:function(t){return ul(t)&&go.call(t,"callee")&&!xV.call(t,"callee")},aE=Array.isArray;function lE(t){return t!=null&&g_(t.length)&&!dE(t)}function UJ(t){return ul(t)&&lE(t)}var h_=PV||FJ;function dE(t){if(!na(t))return!1;var e=JA(t);return e==i_||e==nV||e==XY||e==aV}function g_(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=r_}function na(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}function ul(t){return t!=null&&typeof t=="object"}function MJ(t){if(!ul(t)||JA(t)!=o_)return!1;var e=l_(t);if(e===null)return!0;var r=go.call(e,"constructor")&&e.constructor;return typeof r=="function"&&r instanceof r&&YA.call(r)==UV}var m_=Yv?TV(Yv):AJ;function xJ(t){return CJ(t,y_(t))}function y_(t){return lE(t)?cJ(t,!0):pJ(t)}var LJ=bJ(function(t,e,r){A_(t,e,r)});function PJ(t){return function(){return t}}function E_(t){return t}function FJ(){return!1}Ac.exports=LJ});var O_=g((CRe,k_)=>{"use strict";var B_=200,fE="__lodash_hash_undefined__",$J=1/0,jJ=9007199254740991,qJ="[object Function]",HJ="[object GeneratorFunction]",zJ=/[\\^$.*+?()[\]{}|]/g,GJ=/^\[object .+?Constructor\]$/,YJ=typeof global=="object"&&global&&global.Object===Object&&global,VJ=typeof self=="object"&&self&&self.Object===Object&&self,hE=YJ||VJ||Function("return this")();function JJ(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}function WJ(t,e){for(var r=-1,n=t?t.length:0,i=0,o=[];++r<n;){var s=t[r];e(s,r,t)&&(o[i++]=s)}return o}function w_(t,e){var r=t?t.length:0;return!!r&&eW(t,e,0)>-1}function Q_(t,e,r){for(var n=-1,i=t?t.length:0;++n<i;)if(r(e,t[n]))return!0;return!1}function ZJ(t,e){for(var r=-1,n=t?t.length:0,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}function KJ(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}function XJ(t,e,r,n){for(var i=t.length,o=r+(n?1:-1);n?o--:++o<i;)if(e(t[o],o,t))return o;return-1}function eW(t,e,r){if(e!==e)return XJ(t,tW,r);for(var n=r-1,i=t.length;++n<i;)if(t[n]===e)return n;return-1}function tW(t){return t!==t}function rW(t){return function(e){return t(e)}}function v_(t,e){return t.has(e)}function nW(t,e){return t?.[e]}function iW(t){var e=!1;if(t!=null&&typeof t.toString!="function")try{e=!!(t+"")}catch{}return e}function __(t){var e=-1,r=Array(t.size);return t.forEach(function(n){r[++e]=n}),r}var oW=Array.prototype,sW=Function.prototype,D_=Object.prototype,AE=hE["__core-js_shared__"],C_=(function(){var t=/[^.]+$/.exec(AE&&AE.keys&&AE.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})(),T_=sW.toString,gE=D_.hasOwnProperty,aW=D_.toString,cW=RegExp("^"+T_.call(gE).replace(zJ,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),uW=oW.splice,b_=Math.max,lW=mE(hE,"Map"),pE=mE(hE,"Set"),ll=mE(Object,"create");function ia(t){var e=-1,r=t?t.length:0;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function dW(){this.__data__=ll?ll(null):{}}function AW(t){return this.has(t)&&delete this.__data__[t]}function pW(t){var e=this.__data__;if(ll){var r=e[t];return r===fE?void 0:r}return gE.call(e,t)?e[t]:void 0}function fW(t){var e=this.__data__;return ll?e[t]!==void 0:gE.call(e,t)}function hW(t,e){var r=this.__data__;return r[t]=ll&&e===void 0?fE:e,this}ia.prototype.clear=dW;ia.prototype.delete=AW;ia.prototype.get=pW;ia.prototype.has=fW;ia.prototype.set=hW;function hc(t){var e=-1,r=t?t.length:0;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function gW(){this.__data__=[]}function mW(t){var e=this.__data__,r=KA(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():uW.call(e,r,1),!0}function yW(t){var e=this.__data__,r=KA(e,t);return r<0?void 0:e[r][1]}function EW(t){return KA(this.__data__,t)>-1}function IW(t,e){var r=this.__data__,n=KA(r,t);return n<0?r.push([t,e]):r[n][1]=e,this}hc.prototype.clear=gW;hc.prototype.delete=mW;hc.prototype.get=yW;hc.prototype.has=EW;hc.prototype.set=IW;function gc(t){var e=-1,r=t?t.length:0;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function CW(){this.__data__={hash:new ia,map:new(lW||hc),string:new ia}}function bW(t){return XA(this,t).delete(t)}function SW(t){return XA(this,t).get(t)}function BW(t){return XA(this,t).has(t)}function wW(t,e){return XA(this,t).set(t,e),this}gc.prototype.clear=CW;gc.prototype.delete=bW;gc.prototype.get=SW;gc.prototype.has=BW;gc.prototype.set=wW;function dl(t){var e=-1,r=t?t.length:0;for(this.__data__=new gc;++e<r;)this.add(t[e])}function QW(t){return this.__data__.set(t,fE),this}function vW(t){return this.__data__.has(t)}dl.prototype.add=dl.prototype.push=QW;dl.prototype.has=vW;function KA(t,e){for(var r=t.length;r--;)if(xW(t[r][0],e))return r;return-1}function S_(t,e,r,n){var i=-1,o=w_,s=!0,a=t.length,c=[],u=e.length;if(!a)return c;r&&(e=ZJ(e,rW(r))),n?(o=Q_,s=!1):e.length>=B_&&(o=v_,s=!1,e=new dl(e));e:for(;++i<a;){var l=t[i],d=r?r(l):l;if(l=n||l!==0?l:0,s&&d===d){for(var A=u;A--;)if(e[A]===d)continue e;c.push(l)}else o(e,d,n)||c.push(l)}return c}function _W(t){if(!N_(t)||OW(t))return!1;var e=R_(t)||iW(t)?cW:GJ;return e.test(UW(t))}function DW(t,e){return e=b_(e===void 0?t.length-1:e,0),function(){for(var r=arguments,n=-1,i=b_(r.length-e,0),o=Array(i);++n<i;)o[n]=r[e+n];n=-1;for(var s=Array(e+1);++n<e;)s[n]=r[n];return s[e]=o,JJ(t,this,s)}}function TW(t,e,r){var n=-1,i=w_,o=t.length,s=!0,a=[],c=a;if(r)s=!1,i=Q_;else if(o>=B_){var u=e?null:NW(t);if(u)return __(u);s=!1,i=v_,c=new dl}else c=e?[]:a;e:for(;++n<o;){var l=t[n],d=e?e(l):l;if(l=r||l!==0?l:0,s&&d===d){for(var A=c.length;A--;)if(c[A]===d)continue e;e&&c.push(d),a.push(l)}else i(c,d,r)||(c!==a&&c.push(d),a.push(l))}return a}function RW(t,e,r){for(var n=-1,i=t.length;++n<i;)var o=o?KJ(S_(o,t[n],e,r),S_(t[n],o,e,r)):t[n];return o&&o.length?TW(o,e,r):[]}var NW=pE&&1/__(new pE([,-0]))[1]==$J?function(t){return new pE(t)}:jW;function XA(t,e){var r=t.__data__;return kW(e)?r[typeof e=="string"?"string":"hash"]:r.map}function mE(t,e){var r=nW(t,e);return _W(r)?r:void 0}function kW(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}function OW(t){return!!C_&&C_ in t}function UW(t){if(t!=null){try{return T_.call(t)}catch{}try{return t+""}catch{}}return""}var MW=DW(function(t){return RW(WJ(t,PW))});function xW(t,e){return t===e||t!==t&&e!==e}function LW(t){return t!=null&&FW(t.length)&&!R_(t)}function PW(t){return $W(t)&&LW(t)}function R_(t){var e=N_(t)?aW.call(t):"";return e==qJ||e==HJ}function FW(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=jJ}function N_(t){var e=typeof t;return!!t&&(e=="object"||e=="function")}function $W(t){return!!t&&typeof t=="object"}function jW(){}k_.exports=MW});var tp=g(yo=>{"use strict";var CE=yo&&yo.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(yo,"__esModule",{value:!0});yo.toJsonSchema=VW;yo.convertRequiredToArray=Al;yo.generateDefaultFromSchema=pl;yo.parseJsonSafe=ep;yo.normalizeToolSchemas=JW;var yE=CE(zv()),EE=CE(I_()),qW=CE(O_());function mc(t,e){if(t===e)return!0;if(t===null||e===null||typeof t!="object"||typeof e!="object"||Array.isArray(t)!==Array.isArray(e))return!1;let r=Object.keys(t),n=Object.keys(e);if(r.length!==n.length)return!1;let i=e;return r.every(o=>o in i&&mc(t[o],i[o]))}var HW={required:!1,requiredDepth:Number.POSITIVE_INFINITY,postProcessFnc:null,strings:{preProcessFnc:null},arrays:{mode:"all"},objects:{preProcessFnc:null,postProcessFnc:null,additionalProperties:!0}},zW={string:function(e){return typeof e=="string"},number:function(e){return typeof e=="number"&&isFinite(e)},integer:function(e){return typeof e=="number"&&e%1===0},boolean:function(e){return typeof e=="boolean"},array:function(e){return e instanceof Array},null:function(e){return e===null},date:function(e){return e instanceof Date},any:function(e){return!0},object:function(e){return e&&typeof e=="object"&&!(e instanceof Array)&&!(e instanceof Date)}},yc={typeNames:["integer","number","string","array","object","boolean","null","date"],getType(t){return yc.typeNames.find(e=>zW[e](t))},mergeSchemaObjs(t,e){if(!t||!e)return null;let r=(0,yE.default)(t),n=(0,yE.default)(e);if(!mc(r,n)){if(t.type==="array"&&e.type==="array"&&mc((0,qW.default)(r,n),["items"])){let o=r.length>n.length?e:t,s=r.length>n.length?t:e;if((0,yE.default)(o).reduce((c,u)=>mc(o[u],s[u])&&c,!0))return o}if(t.type!=="object"||e.type!=="object")return null}let i={};for(let o=0,{length:s}=r;o<s;o++){let a=r[o];if(yc.getType(t[a])==="object"){let c=yc.mergeSchemaObjs(t[a],e[a]);if(c)i[a]=c;else{if(t.type==="object"||e.type==="object")return{type:"object"};if(a!=="items"||t.type!=="array"||e.type!=="array")return null}}else if(a==="type")if(t[a]!==e[a])if(t[a]==="integer"&&e[a]==="number"||t[a]==="number"&&e[a]==="integer")i[a]="number";else return null;else i[a]=t[a];else{if(!mc(t[a],e[a]))return null;i[a]=t[a]}}return i}};function GW(t){let e;for(let r=0,{length:n}=t;r<n;r++){let i=t[r];if(r>0&&(i==="integer"&&e==="number"?i="number":i==="number"&&e==="integer"&&(e="number"),e!==i))return null;e=i}return e}function YW(t){return GW(t.map(e=>yc.getType(e)))}var IE=class{constructor(e){this.options=(0,EE.default)({},HW,e),this.depth=0,this.getObjectSchemaDefault=this.getObjectSchemaDefault.bind(this),this.getStringSchemaDefault=this.getStringSchemaDefault.bind(this),this.objectPostProcessDefault=this.objectPostProcessDefault.bind(this),this.commmonPostProcessDefault=this.commmonPostProcessDefault.bind(this),this.objectPostProcessDefault=this.objectPostProcessDefault.bind(this)}getCommonArrayItemSchema(e){let r=e.map(n=>{this.depth++;let i=this.getSchema(n);return this.depth--,i});return r.reduce((n,i)=>yc.mergeSchemaObjs(n,i),r.pop())}getObjectSchemaDefault(e){let r={type:"object"},n=Object.keys(e);return n.length>0&&(r.properties=n.reduce((i,o)=>(this.depth++,i[o]=this.getSchema(e[o]),this.depth--,i),{})),r}getObjectSchema(e){return this.options.objects.preProcessFnc?this.options.objects.preProcessFnc(e,this.getObjectSchemaDefault):this.getObjectSchemaDefault(e)}getArraySchemaMerging(e){let r={type:"array"},n=YW(e);if(n)if(r.items={type:n},n!=="integer"&&n!=="number"){let i=this.getCommonArrayItemSchema(e);i&&(r.items=i)}else this.options.required&&(r.items.required=!0);return r}getArraySchemaNoMerging(e){let r={type:"array"};return e.length>0&&(this.depth++,r.items=this.getSchema(e[0]),this.depth--),r}getArraySchemaTuple(e){let r={type:"array"};return e.length>0&&(r.items=e.map(n=>{this.depth++;let i=this.getSchema(n);return this.depth--,i})),r}getArraySchemaUniform(e){let r=this.getArraySchemaNoMerging(e);if(e.length>1)for(let n=1;n<e.length;n++){this.depth++;let i=this.getSchema(e[n]);if(this.depth--,!mc(r.items,i))throw new Error("Invalid schema, incompatible array items")}return r}getArraySchema(e){if(e.length===0)return{type:"array"};switch(this.options.arrays.mode){case"all":return this.getArraySchemaMerging(e);case"first":return this.getArraySchemaNoMerging(e);case"uniform":return this.getArraySchemaUniform(e);case"tuple":return this.getArraySchemaTuple(e);default:throw new Error(`Unknown array mode option '${this.options.arrays.mode}'`)}}getStringSchemaDefault(e){return{type:"string"}}getStringSchema(e){return this.options.strings.preProcessFnc?this.options.strings.preProcessFnc(e,this.getStringSchemaDefault):this.getStringSchemaDefault(e)}commmonPostProcessDefault(e,r,n){return this.options.required&&this.depth<=this.options.requiredDepth?(0,EE.default)({},r,{required:!0}):r}objectPostProcessDefault(e,r){return this.options.objects.additionalProperties===!1&&Object.getOwnPropertyNames(r).length>0?(0,EE.default)({},e,{additionalProperties:!1}):e}getSchema(e){let r=yc.getType(e);r||(r="null");let n;switch(r){case"object":n=this.getObjectSchema(e);break;case"array":n=this.getArraySchema(e);break;case"string":n=this.getStringSchema(e);break;default:n={type:r}}return this.options.postProcessFnc?n=this.options.postProcessFnc(r,n,e,this.commmonPostProcessDefault):n=this.commmonPostProcessDefault(r,n,e),r==="object"&&(this.options.objects.postProcessFnc?n=this.options.objects.postProcessFnc(n,e,this.objectPostProcessDefault):n=this.objectPostProcessDefault(n,e)),n}};function VW(t,e){return new IE(e).getSchema(t)}function Al(t){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(r=>Al(r));let e={...t};if(delete e.required,e.properties&&typeof e.properties=="object"){let r=[],n={};for(let[i,o]of Object.entries(e.properties)){let s=o;if(s&&typeof s=="object"&&s.required===!0){r.push(i);let{required:a,...c}=s;n[i]=Al(c)}else n[i]=Al(s)}e.properties=n,r.length>0&&(e.required=r)}return e.items&&(e.items=Al(e.items)),e}function pl(t){if(!t||typeof t!="object")return null;if(t.const!==void 0)return t.const;if(t.enum&&Array.isArray(t.enum)&&t.enum.length>0)return t.enum[0];if(t.default!==void 0)return t.default;if(t.oneOf&&Array.isArray(t.oneOf)&&t.oneOf.length>0)return pl(t.oneOf[0]);if(t.anyOf&&Array.isArray(t.anyOf)&&t.anyOf.length>0)return pl(t.anyOf[0]);switch(Array.isArray(t.type)?t.type[0]:t.type){case"string":case"number":case"integer":case"boolean":return null;case"null":return null;case"array":return t.items?[]:[];case"object":let r={};if(t.properties&&typeof t.properties=="object"){let n=t.required||[];for(let[i,o]of Object.entries(t.properties))r[i]=pl(o)}return r;default:if(t.properties&&typeof t.properties=="object"){let n={};for(let[i,o]of Object.entries(t.properties))n[i]=pl(o);return n}return null}}function ep(t){if(typeof t!="string")return t;try{return JSON.parse(t)}catch{return t}}function JW(t){let e={...t};return e.inputSchema&&(e.inputSchema=ep(e.inputSchema)),e.outputSchema&&(e.outputSchema=ep(e.outputSchema)),e.responseSchema&&(e.responseSchema=ep(e.responseSchema)),e}});var Br=g(M=>{"use strict";Object.defineProperty(M,"__esModule",{value:!0});M.PLAYBOOK_LIMITS=M.MCP_SERVER_AUTH_MODES=M.OAUTH_POPUP_CLOSED_MESSAGE=M.OAUTH_CONTINUATION_REASON_MAX_CHARS=M.AGENT_REQUEST_BUSY_STATUSES=M.AGENT_SESSION_USER_OPENED_METADATA_KEY=M.AGENT_SESSION_RESOURCE_KINDS=M.AGENT_MESSAGE_SCHEMA_VERSION=M.AGENT_APPROVAL_MODES=M.ConfirmationAction=M.LOADABLE_MARKDOWN_NAMES=M.SKILL_REFERENCE_NAMES=M.SKILL_BODY_NAMES=M.AGENT_CHECKLIST_MAX_LABEL_CHARS=M.AGENT_CHECKLIST_MAX_ITEMS=M.AGENT_CHECKLIST_MIN_ITEMS=M.DYNAMIC_AGENT_TOOLS=M.AGENT_TOOLS=M.AGENT_NATIVE_TOOLS=M.PLAYBOOK_PLAYGROUND_DRAFT_ID=M.PLAYGROUND_TOOL_DRAFT_ID=M.AgentType=M.FileStatus=M.MAX_BULK_RESOURCE_SHARE_OPERATIONS=M.MAX_BULK_MUTATION_IDS=M.RunExecutionKind=M.RequestSource=M.RunStatus=M.CredentialMode=M.UpsertMode=M.LogLevel=M.PaginationType=M.DecompressionMethod=M.AuthType=M.FileType=M.CacheMode=M.HttpMethod=M.SupportedFileType=M.RUN_COMMAND_EFFECT_KINDS=M.CONNECTION_PROTOCOLS=void 0;M.isRequestConfig=WW;M.isTransformConfig=ZW;M.isAgentSessionOpenedByUser=KW;M.CONNECTION_PROTOCOLS=["http","postgres","mssql","redis","mongodb","sftp","smb","odbc","script","suitecloud"];M.RUN_COMMAND_EFFECT_KINDS=["tool","tool_state","system","project","schedule","session","briefing","mcp_server","role","playbook","artifact","share","org_settings","file","memory"];var U_;(function(t){t.JSON="JSON",t.CSV="CSV",t.XML="XML",t.HTML="HTML",t.YAML="YAML",t.EXCEL="EXCEL",t.PDF="PDF",t.DOCX="DOCX",t.PPTX="PPTX",t.ZIP="ZIP",t.GZIP="GZIP",t.BINARY="BINARY",t.RAW="RAW",t.AUTO="AUTO"})(U_||(M.SupportedFileType=U_={}));var M_;(function(t){t.GET="GET",t.POST="POST",t.PUT="PUT",t.DELETE="DELETE",t.PATCH="PATCH",t.HEAD="HEAD",t.OPTIONS="OPTIONS"})(M_||(M.HttpMethod=M_={}));var x_;(function(t){t.ENABLED="ENABLED",t.READONLY="READONLY",t.WRITEONLY="WRITEONLY",t.DISABLED="DISABLED"})(x_||(M.CacheMode=x_={}));var L_;(function(t){t.CSV="CSV",t.JSON="JSON",t.XML="XML",t.YAML="YAML",t.EXCEL="EXCEL",t.HTML="HTML",t.PDF="PDF",t.DOCX="DOCX",t.PPTX="PPTX",t.ZIP="ZIP",t.BINARY="BINARY",t.RAW="RAW",t.AUTO="AUTO"})(L_||(M.FileType=L_={}));var P_;(function(t){t.NONE="NONE",t.OAUTH2="OAUTH2",t.HEADER="HEADER",t.QUERY_PARAM="QUERY_PARAM"})(P_||(M.AuthType=P_={}));var F_;(function(t){t.GZIP="GZIP",t.DEFLATE="DEFLATE",t.NONE="NONE",t.AUTO="AUTO",t.ZIP="ZIP"})(F_||(M.DecompressionMethod=F_={}));var $_;(function(t){t.OFFSET_BASED="OFFSET_BASED",t.PAGE_BASED="PAGE_BASED",t.CURSOR_BASED="CURSOR_BASED",t.DISABLED="DISABLED"})($_||(M.PaginationType=$_={}));var j_;(function(t){t.DEBUG="DEBUG",t.INFO="INFO",t.WARN="WARN",t.ERROR="ERROR"})(j_||(M.LogLevel=j_={}));var q_;(function(t){t.CREATE="CREATE",t.UPDATE="UPDATE",t.UPSERT="UPSERT"})(q_||(M.UpsertMode=q_={}));var H_;(function(t){t.MERGE="MERGE",t.REPLACE="REPLACE"})(H_||(M.CredentialMode=H_={}));var z_;(function(t){t.RUNNING="RUNNING",t.SUCCESS="SUCCESS",t.FAILED="FAILED",t.ABORTED="ABORTED"})(z_||(M.RunStatus=z_={}));var G_;(function(t){t.API="api",t.FRONTEND="frontend",t.AGENT="agent",t.SCHEDULER="scheduler",t.MCP="mcp",t.TOOL_CHAIN="tool-chain",t.WEBHOOK="webhook",t.CLI="cli"})(G_||(M.RequestSource=G_={}));var Y_;(function(t){t.FULL="full",t.DRAFT="draft",t.SINGLE_STEP="single-step"})(Y_||(M.RunExecutionKind=Y_={}));M.MAX_BULK_MUTATION_IDS=100;M.MAX_BULK_RESOURCE_SHARE_OPERATIONS=1e3;function WW(t){return!t||typeof t!="object"?!1:t.type==="request"||!("type"in t)||t.type===void 0}function ZW(t){return t?.type==="transform"}var V_;(function(t){t.PENDING="PENDING",t.UPLOADING="UPLOADING",t.PROCESSING="PROCESSING",t.COMPLETED="COMPLETED",t.FAILED="FAILED"})(V_||(M.FileStatus=V_={}));var ts;(function(t){t.MAIN="main",t.PLAYGROUND="playground",t.SYSTEM_PLAYGROUND="system_playground",t.PLAYBOOK_PLAYGROUND="playbook_playground",t.ARTIFACT_PLAYGROUND="artifact_playground",t.ACCESS_RULES="access_rules"})(ts||(M.AgentType=ts={}));M.PLAYGROUND_TOOL_DRAFT_ID="@playground-draft";M.PLAYBOOK_PLAYGROUND_DRAFT_ID="@playground-draft";M.AGENT_NATIVE_TOOLS=["run_command","load_skill","use_checklist","set_credentials","authenticate_oauth","setup_gateway"];M.AGENT_TOOLS={[ts.MAIN]:[...M.AGENT_NATIVE_TOOLS],[ts.PLAYGROUND]:[...M.AGENT_NATIVE_TOOLS],[ts.SYSTEM_PLAYGROUND]:[...M.AGENT_NATIVE_TOOLS],[ts.PLAYBOOK_PLAYGROUND]:[...M.AGENT_NATIVE_TOOLS],[ts.ARTIFACT_PLAYGROUND]:[...M.AGENT_NATIVE_TOOLS],[ts.ACCESS_RULES]:[...M.AGENT_NATIVE_TOOLS]};M.DYNAMIC_AGENT_TOOLS=["web_search"];M.AGENT_CHECKLIST_MIN_ITEMS=4;M.AGENT_CHECKLIST_MAX_ITEMS=15;M.AGENT_CHECKLIST_MAX_LABEL_CHARS=120;M.SKILL_BODY_NAMES=["superglue-info","tools","systems","access-management","tool-deployment","notifications","artifacts","playbooks","projects","superglue-brain","email","workspace-apps","meetings","brand-guidelines","demos"];M.SKILL_REFERENCE_NAMES=["http","graphql","postgres","mssql","odbc","redis","mongodb","sftp-smb","suitecloud","tool-files","tunnel-handling"];M.LOADABLE_MARKDOWN_NAMES=[...M.SKILL_BODY_NAMES,...M.SKILL_REFERENCE_NAMES];var J_;(function(t){t.CONFIRMED="confirmed",t.DECLINED="declined",t.OAUTH_SUCCESS="oauth_success",t.OAUTH_FAILURE="oauth_failure"})(J_||(M.ConfirmationAction=J_={}));M.AGENT_APPROVAL_MODES=["ask","act"];M.AGENT_MESSAGE_SCHEMA_VERSION=1;M.AGENT_SESSION_RESOURCE_KINDS=["tool","system","playbook","artifact","briefing"];M.AGENT_SESSION_USER_OPENED_METADATA_KEY="userOpened";function KW(t){return t[M.AGENT_SESSION_USER_OPENED_METADATA_KEY]===!0}M.AGENT_REQUEST_BUSY_STATUSES=["queued","claimed","running","cancelling"];M.OAUTH_CONTINUATION_REASON_MAX_CHARS=500;M.OAUTH_POPUP_CLOSED_MESSAGE="OAuth authentication did not complete.";M.MCP_SERVER_AUTH_MODES=["oauth","creator_api_key"];M.PLAYBOOK_LIMITS={name:120,whenToRun:500,inputs:25e3,instructions:1e5,completionCriteria:25e3,systemRefs:10,toolRefs:25,credentialRefs:10,fileRefs:15,compiledRender:512e3}});var XW,Z_,W_,e4,t4,r4,n4,K_=He(()=>{"use strict";XW=t=>{let e=W_(t,0);if(e===void 0||!t4(t[e]))return;let r=W_(t,e+1);if(r!==void 0)return r4(t,e,r)},Z_=XW,W_=(t,e)=>{for(let r=e;r<t.length;r+=1){let n=t[r];if(!e4(n))return r}},e4=t=>t===" "||t===" "||t===`
|
|
2
|
+
"use strict";var BY=Object.create;var jA=Object.defineProperty;var wY=Object.getOwnPropertyDescriptor;var QY=Object.getOwnPropertyNames;var vY=Object.getPrototypeOf,_Y=Object.prototype.hasOwnProperty;var He=(t,e)=>()=>(t&&(e=t(t=0)),e);var g=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Pv=(t,e)=>{for(var r in e)jA(t,r,{get:e[r],enumerable:!0})},Fv=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of QY(e))!_Y.call(t,i)&&i!==r&&jA(t,i,{get:()=>e[i],enumerable:!(n=wY(e,i))||n.enumerable});return t};var ge=(t,e,r)=>(r=t!=null?BY(vY(t)):{},Fv(e||!t||!t.__esModule?jA(r,"default",{value:t,enumerable:!0}):r,t)),eE=t=>Fv(jA({},"__esModule",{value:!0}),t);var zv=g((IRe,Hv)=>{"use strict";var $v=9007199254740991,DY="[object Arguments]",TY="[object Function]",RY="[object GeneratorFunction]",NY=/^(?:0|[1-9]\d*)$/;function kY(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}function OY(t,e){return function(r){return t(e(r))}}var qA=Object.prototype,tE=qA.hasOwnProperty,jv=qA.toString,UY=qA.propertyIsEnumerable,MY=OY(Object.keys,Object);function xY(t,e){var r=jY(t)||$Y(t)?kY(t.length,String):[],n=r.length,i=!!n;for(var o in t)(e||tE.call(t,o))&&!(i&&(o=="length"||PY(o,n)))&&r.push(o);return r}function LY(t){if(!FY(t))return MY(t);var e=[];for(var r in Object(t))tE.call(t,r)&&r!="constructor"&&e.push(r);return e}function PY(t,e){return e=e??$v,!!e&&(typeof t=="number"||NY.test(t))&&t>-1&&t%1==0&&t<e}function FY(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||qA;return t===r}function $Y(t){return qY(t)&&tE.call(t,"callee")&&(!UY.call(t,"callee")||jv.call(t)==DY)}var jY=Array.isArray;function qv(t){return t!=null&&zY(t.length)&&!HY(t)}function qY(t){return YY(t)&&qv(t)}function HY(t){var e=GY(t)?jv.call(t):"";return e==TY||e==RY}function zY(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=$v}function GY(t){var e=typeof t;return!!t&&(e=="object"||e=="function")}function YY(t){return!!t&&typeof t=="object"}function VY(t){return qv(t)?xY(t):LY(t)}Hv.exports=VY});var I_=g((ol,Ac)=>{"use strict";var JY=200,t_="__lodash_hash_undefined__",WY=800,ZY=16,r_=9007199254740991,n_="[object Arguments]",KY="[object Array]",XY="[object AsyncFunction]",eV="[object Boolean]",tV="[object Date]",rV="[object Error]",i_="[object Function]",nV="[object GeneratorFunction]",iV="[object Map]",oV="[object Number]",sV="[object Null]",o_="[object Object]",aV="[object Proxy]",cV="[object RegExp]",uV="[object Set]",lV="[object String]",dV="[object Undefined]",AV="[object WeakMap]",pV="[object ArrayBuffer]",fV="[object DataView]",hV="[object Float32Array]",gV="[object Float64Array]",mV="[object Int8Array]",yV="[object Int16Array]",EV="[object Int32Array]",IV="[object Uint8Array]",CV="[object Uint8ClampedArray]",bV="[object Uint16Array]",SV="[object Uint32Array]",BV=/[\\^$.*+?()[\]{}|]/g,wV=/^\[object .+?Constructor\]$/,QV=/^(?:0|[1-9]\d*)$/,Ve={};Ve[hV]=Ve[gV]=Ve[mV]=Ve[yV]=Ve[EV]=Ve[IV]=Ve[CV]=Ve[bV]=Ve[SV]=!0;Ve[n_]=Ve[KY]=Ve[pV]=Ve[eV]=Ve[fV]=Ve[tV]=Ve[rV]=Ve[i_]=Ve[iV]=Ve[oV]=Ve[o_]=Ve[cV]=Ve[uV]=Ve[lV]=Ve[AV]=!1;var s_=typeof global=="object"&&global&&global.Object===Object&&global,vV=typeof self=="object"&&self&&self.Object===Object&&self,cl=s_||vV||Function("return this")(),a_=typeof ol=="object"&&ol&&!ol.nodeType&&ol,sl=a_&&typeof Ac=="object"&&Ac&&!Ac.nodeType&&Ac,c_=sl&&sl.exports===a_,rE=c_&&s_.process,Gv=(function(){try{var t=sl&&sl.require&&sl.require("util").types;return t||rE&&rE.binding&&rE.binding("util")}catch{}})(),Yv=Gv&&Gv.isTypedArray;function _V(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}function DV(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}function TV(t){return function(e){return t(e)}}function RV(t,e){return t?.[e]}function NV(t,e){return function(r){return t(e(r))}}var kV=Array.prototype,OV=Function.prototype,GA=Object.prototype,nE=cl["__core-js_shared__"],YA=OV.toString,go=GA.hasOwnProperty,Vv=(function(){var t=/[^.]+$/.exec(nE&&nE.keys&&nE.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})(),u_=GA.toString,UV=YA.call(Object),MV=RegExp("^"+YA.call(go).replace(BV,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),HA=c_?cl.Buffer:void 0,Jv=cl.Symbol,Wv=cl.Uint8Array,Zv=HA?HA.allocUnsafe:void 0,l_=NV(Object.getPrototypeOf,Object),Kv=Object.create,xV=GA.propertyIsEnumerable,LV=kV.splice,ta=Jv?Jv.toStringTag:void 0,zA=(function(){try{var t=uE(Object,"defineProperty");return t({},"",{}),t}catch{}})(),PV=HA?HA.isBuffer:void 0,Xv=Math.max,FV=Date.now,d_=uE(cl,"Map"),al=uE(Object,"create"),$V=(function(){function t(){}return function(e){if(!na(e))return{};if(Kv)return Kv(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}})();function ra(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function jV(){this.__data__=al?al(null):{},this.size=0}function qV(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}function HV(t){var e=this.__data__;if(al){var r=e[t];return r===t_?void 0:r}return go.call(e,t)?e[t]:void 0}function zV(t){var e=this.__data__;return al?e[t]!==void 0:go.call(e,t)}function GV(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=al&&e===void 0?t_:e,this}ra.prototype.clear=jV;ra.prototype.delete=qV;ra.prototype.get=HV;ra.prototype.has=zV;ra.prototype.set=GV;function mo(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function YV(){this.__data__=[],this.size=0}function VV(t){var e=this.__data__,r=VA(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():LV.call(e,r,1),--this.size,!0}function JV(t){var e=this.__data__,r=VA(e,t);return r<0?void 0:e[r][1]}function WV(t){return VA(this.__data__,t)>-1}function ZV(t,e){var r=this.__data__,n=VA(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}mo.prototype.clear=YV;mo.prototype.delete=VV;mo.prototype.get=JV;mo.prototype.has=WV;mo.prototype.set=ZV;function pc(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function KV(){this.size=0,this.__data__={hash:new ra,map:new(d_||mo),string:new ra}}function XV(t){var e=WA(this,t).delete(t);return this.size-=e?1:0,e}function eJ(t){return WA(this,t).get(t)}function tJ(t){return WA(this,t).has(t)}function rJ(t,e){var r=WA(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}pc.prototype.clear=KV;pc.prototype.delete=XV;pc.prototype.get=eJ;pc.prototype.has=tJ;pc.prototype.set=rJ;function fc(t){var e=this.__data__=new mo(t);this.size=e.size}function nJ(){this.__data__=new mo,this.size=0}function iJ(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}function oJ(t){return this.__data__.get(t)}function sJ(t){return this.__data__.has(t)}function aJ(t,e){var r=this.__data__;if(r instanceof mo){var n=r.__data__;if(!d_||n.length<JY-1)return n.push([t,e]),this.size=++r.size,this;r=this.__data__=new pc(n)}return r.set(t,e),this.size=r.size,this}fc.prototype.clear=nJ;fc.prototype.delete=iJ;fc.prototype.get=oJ;fc.prototype.has=sJ;fc.prototype.set=aJ;function cJ(t,e){var r=aE(t),n=!r&&sE(t),i=!r&&!n&&h_(t),o=!r&&!n&&!i&&m_(t),s=r||n||i||o,a=s?DV(t.length,String):[],c=a.length;for(var u in t)(e||go.call(t,u))&&!(s&&(u=="length"||i&&(u=="offset"||u=="parent")||o&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||p_(u,c)))&&a.push(u);return a}function iE(t,e,r){(r!==void 0&&!ZA(t[e],r)||r===void 0&&!(e in t))&&cE(t,e,r)}function uJ(t,e,r){var n=t[e];(!(go.call(t,e)&&ZA(n,r))||r===void 0&&!(e in t))&&cE(t,e,r)}function VA(t,e){for(var r=t.length;r--;)if(ZA(t[r][0],e))return r;return-1}function cE(t,e,r){e=="__proto__"&&zA?zA(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}var lJ=SJ();function JA(t){return t==null?t===void 0?dV:sV:ta&&ta in Object(t)?BJ(t):TJ(t)}function e_(t){return ul(t)&&JA(t)==n_}function dJ(t){if(!na(t)||_J(t))return!1;var e=dE(t)?MV:wV;return e.test(OJ(t))}function AJ(t){return ul(t)&&g_(t.length)&&!!Ve[JA(t)]}function pJ(t){if(!na(t))return DJ(t);var e=f_(t),r=[];for(var n in t)n=="constructor"&&(e||!go.call(t,n))||r.push(n);return r}function A_(t,e,r,n,i){t!==e&&lJ(e,function(o,s){if(i||(i=new fc),na(o))fJ(t,e,s,r,A_,n,i);else{var a=n?n(oE(t,s),o,s+"",t,e,i):void 0;a===void 0&&(a=o),iE(t,s,a)}},y_)}function fJ(t,e,r,n,i,o,s){var a=oE(t,r),c=oE(e,r),u=s.get(c);if(u){iE(t,r,u);return}var l=o?o(a,c,r+"",t,e,s):void 0,d=l===void 0;if(d){var A=aE(c),p=!A&&h_(c),h=!A&&!p&&m_(c);l=c,A||p||h?aE(a)?l=a:UJ(a)?l=IJ(a):p?(d=!1,l=mJ(c,!0)):h?(d=!1,l=EJ(c,!0)):l=[]:MJ(c)||sE(c)?(l=a,sE(a)?l=xJ(a):(!na(a)||dE(a))&&(l=wJ(c))):d=!1}d&&(s.set(c,l),i(l,c,n,o,s),s.delete(c)),iE(t,r,l)}function hJ(t,e){return NJ(RJ(t,e,E_),t+"")}var gJ=zA?function(t,e){return zA(t,"toString",{configurable:!0,enumerable:!1,value:PJ(e),writable:!0})}:E_;function mJ(t,e){if(e)return t.slice();var r=t.length,n=Zv?Zv(r):new t.constructor(r);return t.copy(n),n}function yJ(t){var e=new t.constructor(t.byteLength);return new Wv(e).set(new Wv(t)),e}function EJ(t,e){var r=e?yJ(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}function IJ(t,e){var r=-1,n=t.length;for(e||(e=Array(n));++r<n;)e[r]=t[r];return e}function CJ(t,e,r,n){var i=!r;r||(r={});for(var o=-1,s=e.length;++o<s;){var a=e[o],c=n?n(r[a],t[a],a,r,t):void 0;c===void 0&&(c=t[a]),i?cE(r,a,c):uJ(r,a,c)}return r}function bJ(t){return hJ(function(e,r){var n=-1,i=r.length,o=i>1?r[i-1]:void 0,s=i>2?r[2]:void 0;for(o=t.length>3&&typeof o=="function"?(i--,o):void 0,s&&QJ(r[0],r[1],s)&&(o=i<3?void 0:o,i=1),e=Object(e);++n<i;){var a=r[n];a&&t(e,a,n,o)}return e})}function SJ(t){return function(e,r,n){for(var i=-1,o=Object(e),s=n(e),a=s.length;a--;){var c=s[t?a:++i];if(r(o[c],c,o)===!1)break}return e}}function WA(t,e){var r=t.__data__;return vJ(e)?r[typeof e=="string"?"string":"hash"]:r.map}function uE(t,e){var r=RV(t,e);return dJ(r)?r:void 0}function BJ(t){var e=go.call(t,ta),r=t[ta];try{t[ta]=void 0;var n=!0}catch{}var i=u_.call(t);return n&&(e?t[ta]=r:delete t[ta]),i}function wJ(t){return typeof t.constructor=="function"&&!f_(t)?$V(l_(t)):{}}function p_(t,e){var r=typeof t;return e=e??r_,!!e&&(r=="number"||r!="symbol"&&QV.test(t))&&t>-1&&t%1==0&&t<e}function QJ(t,e,r){if(!na(r))return!1;var n=typeof e;return(n=="number"?lE(r)&&p_(e,r.length):n=="string"&&e in r)?ZA(r[e],t):!1}function vJ(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}function _J(t){return!!Vv&&Vv in t}function f_(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||GA;return t===r}function DJ(t){var e=[];if(t!=null)for(var r in Object(t))e.push(r);return e}function TJ(t){return u_.call(t)}function RJ(t,e,r){return e=Xv(e===void 0?t.length-1:e,0),function(){for(var n=arguments,i=-1,o=Xv(n.length-e,0),s=Array(o);++i<o;)s[i]=n[e+i];i=-1;for(var a=Array(e+1);++i<e;)a[i]=n[i];return a[e]=r(s),_V(t,this,a)}}function oE(t,e){if(!(e==="constructor"&&typeof t[e]=="function")&&e!="__proto__")return t[e]}var NJ=kJ(gJ);function kJ(t){var e=0,r=0;return function(){var n=FV(),i=ZY-(n-r);if(r=n,i>0){if(++e>=WY)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}function OJ(t){if(t!=null){try{return YA.call(t)}catch{}try{return t+""}catch{}}return""}function ZA(t,e){return t===e||t!==t&&e!==e}var sE=e_((function(){return arguments})())?e_:function(t){return ul(t)&&go.call(t,"callee")&&!xV.call(t,"callee")},aE=Array.isArray;function lE(t){return t!=null&&g_(t.length)&&!dE(t)}function UJ(t){return ul(t)&&lE(t)}var h_=PV||FJ;function dE(t){if(!na(t))return!1;var e=JA(t);return e==i_||e==nV||e==XY||e==aV}function g_(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=r_}function na(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}function ul(t){return t!=null&&typeof t=="object"}function MJ(t){if(!ul(t)||JA(t)!=o_)return!1;var e=l_(t);if(e===null)return!0;var r=go.call(e,"constructor")&&e.constructor;return typeof r=="function"&&r instanceof r&&YA.call(r)==UV}var m_=Yv?TV(Yv):AJ;function xJ(t){return CJ(t,y_(t))}function y_(t){return lE(t)?cJ(t,!0):pJ(t)}var LJ=bJ(function(t,e,r){A_(t,e,r)});function PJ(t){return function(){return t}}function E_(t){return t}function FJ(){return!1}Ac.exports=LJ});var O_=g((CRe,k_)=>{"use strict";var B_=200,fE="__lodash_hash_undefined__",$J=1/0,jJ=9007199254740991,qJ="[object Function]",HJ="[object GeneratorFunction]",zJ=/[\\^$.*+?()[\]{}|]/g,GJ=/^\[object .+?Constructor\]$/,YJ=typeof global=="object"&&global&&global.Object===Object&&global,VJ=typeof self=="object"&&self&&self.Object===Object&&self,hE=YJ||VJ||Function("return this")();function JJ(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}function WJ(t,e){for(var r=-1,n=t?t.length:0,i=0,o=[];++r<n;){var s=t[r];e(s,r,t)&&(o[i++]=s)}return o}function w_(t,e){var r=t?t.length:0;return!!r&&eW(t,e,0)>-1}function Q_(t,e,r){for(var n=-1,i=t?t.length:0;++n<i;)if(r(e,t[n]))return!0;return!1}function ZJ(t,e){for(var r=-1,n=t?t.length:0,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}function KJ(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}function XJ(t,e,r,n){for(var i=t.length,o=r+(n?1:-1);n?o--:++o<i;)if(e(t[o],o,t))return o;return-1}function eW(t,e,r){if(e!==e)return XJ(t,tW,r);for(var n=r-1,i=t.length;++n<i;)if(t[n]===e)return n;return-1}function tW(t){return t!==t}function rW(t){return function(e){return t(e)}}function v_(t,e){return t.has(e)}function nW(t,e){return t?.[e]}function iW(t){var e=!1;if(t!=null&&typeof t.toString!="function")try{e=!!(t+"")}catch{}return e}function __(t){var e=-1,r=Array(t.size);return t.forEach(function(n){r[++e]=n}),r}var oW=Array.prototype,sW=Function.prototype,D_=Object.prototype,AE=hE["__core-js_shared__"],C_=(function(){var t=/[^.]+$/.exec(AE&&AE.keys&&AE.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})(),T_=sW.toString,gE=D_.hasOwnProperty,aW=D_.toString,cW=RegExp("^"+T_.call(gE).replace(zJ,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),uW=oW.splice,b_=Math.max,lW=mE(hE,"Map"),pE=mE(hE,"Set"),ll=mE(Object,"create");function ia(t){var e=-1,r=t?t.length:0;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function dW(){this.__data__=ll?ll(null):{}}function AW(t){return this.has(t)&&delete this.__data__[t]}function pW(t){var e=this.__data__;if(ll){var r=e[t];return r===fE?void 0:r}return gE.call(e,t)?e[t]:void 0}function fW(t){var e=this.__data__;return ll?e[t]!==void 0:gE.call(e,t)}function hW(t,e){var r=this.__data__;return r[t]=ll&&e===void 0?fE:e,this}ia.prototype.clear=dW;ia.prototype.delete=AW;ia.prototype.get=pW;ia.prototype.has=fW;ia.prototype.set=hW;function hc(t){var e=-1,r=t?t.length:0;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function gW(){this.__data__=[]}function mW(t){var e=this.__data__,r=KA(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():uW.call(e,r,1),!0}function yW(t){var e=this.__data__,r=KA(e,t);return r<0?void 0:e[r][1]}function EW(t){return KA(this.__data__,t)>-1}function IW(t,e){var r=this.__data__,n=KA(r,t);return n<0?r.push([t,e]):r[n][1]=e,this}hc.prototype.clear=gW;hc.prototype.delete=mW;hc.prototype.get=yW;hc.prototype.has=EW;hc.prototype.set=IW;function gc(t){var e=-1,r=t?t.length:0;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function CW(){this.__data__={hash:new ia,map:new(lW||hc),string:new ia}}function bW(t){return XA(this,t).delete(t)}function SW(t){return XA(this,t).get(t)}function BW(t){return XA(this,t).has(t)}function wW(t,e){return XA(this,t).set(t,e),this}gc.prototype.clear=CW;gc.prototype.delete=bW;gc.prototype.get=SW;gc.prototype.has=BW;gc.prototype.set=wW;function dl(t){var e=-1,r=t?t.length:0;for(this.__data__=new gc;++e<r;)this.add(t[e])}function QW(t){return this.__data__.set(t,fE),this}function vW(t){return this.__data__.has(t)}dl.prototype.add=dl.prototype.push=QW;dl.prototype.has=vW;function KA(t,e){for(var r=t.length;r--;)if(xW(t[r][0],e))return r;return-1}function S_(t,e,r,n){var i=-1,o=w_,s=!0,a=t.length,c=[],u=e.length;if(!a)return c;r&&(e=ZJ(e,rW(r))),n?(o=Q_,s=!1):e.length>=B_&&(o=v_,s=!1,e=new dl(e));e:for(;++i<a;){var l=t[i],d=r?r(l):l;if(l=n||l!==0?l:0,s&&d===d){for(var A=u;A--;)if(e[A]===d)continue e;c.push(l)}else o(e,d,n)||c.push(l)}return c}function _W(t){if(!N_(t)||OW(t))return!1;var e=R_(t)||iW(t)?cW:GJ;return e.test(UW(t))}function DW(t,e){return e=b_(e===void 0?t.length-1:e,0),function(){for(var r=arguments,n=-1,i=b_(r.length-e,0),o=Array(i);++n<i;)o[n]=r[e+n];n=-1;for(var s=Array(e+1);++n<e;)s[n]=r[n];return s[e]=o,JJ(t,this,s)}}function TW(t,e,r){var n=-1,i=w_,o=t.length,s=!0,a=[],c=a;if(r)s=!1,i=Q_;else if(o>=B_){var u=e?null:NW(t);if(u)return __(u);s=!1,i=v_,c=new dl}else c=e?[]:a;e:for(;++n<o;){var l=t[n],d=e?e(l):l;if(l=r||l!==0?l:0,s&&d===d){for(var A=c.length;A--;)if(c[A]===d)continue e;e&&c.push(d),a.push(l)}else i(c,d,r)||(c!==a&&c.push(d),a.push(l))}return a}function RW(t,e,r){for(var n=-1,i=t.length;++n<i;)var o=o?KJ(S_(o,t[n],e,r),S_(t[n],o,e,r)):t[n];return o&&o.length?TW(o,e,r):[]}var NW=pE&&1/__(new pE([,-0]))[1]==$J?function(t){return new pE(t)}:jW;function XA(t,e){var r=t.__data__;return kW(e)?r[typeof e=="string"?"string":"hash"]:r.map}function mE(t,e){var r=nW(t,e);return _W(r)?r:void 0}function kW(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}function OW(t){return!!C_&&C_ in t}function UW(t){if(t!=null){try{return T_.call(t)}catch{}try{return t+""}catch{}}return""}var MW=DW(function(t){return RW(WJ(t,PW))});function xW(t,e){return t===e||t!==t&&e!==e}function LW(t){return t!=null&&FW(t.length)&&!R_(t)}function PW(t){return $W(t)&&LW(t)}function R_(t){var e=N_(t)?aW.call(t):"";return e==qJ||e==HJ}function FW(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=jJ}function N_(t){var e=typeof t;return!!t&&(e=="object"||e=="function")}function $W(t){return!!t&&typeof t=="object"}function jW(){}k_.exports=MW});var tp=g(yo=>{"use strict";var CE=yo&&yo.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(yo,"__esModule",{value:!0});yo.toJsonSchema=VW;yo.convertRequiredToArray=Al;yo.generateDefaultFromSchema=pl;yo.parseJsonSafe=ep;yo.normalizeToolSchemas=JW;var yE=CE(zv()),EE=CE(I_()),qW=CE(O_());function mc(t,e){if(t===e)return!0;if(t===null||e===null||typeof t!="object"||typeof e!="object"||Array.isArray(t)!==Array.isArray(e))return!1;let r=Object.keys(t),n=Object.keys(e);if(r.length!==n.length)return!1;let i=e;return r.every(o=>o in i&&mc(t[o],i[o]))}var HW={required:!1,requiredDepth:Number.POSITIVE_INFINITY,postProcessFnc:null,strings:{preProcessFnc:null},arrays:{mode:"all"},objects:{preProcessFnc:null,postProcessFnc:null,additionalProperties:!0}},zW={string:function(e){return typeof e=="string"},number:function(e){return typeof e=="number"&&isFinite(e)},integer:function(e){return typeof e=="number"&&e%1===0},boolean:function(e){return typeof e=="boolean"},array:function(e){return e instanceof Array},null:function(e){return e===null},date:function(e){return e instanceof Date},any:function(e){return!0},object:function(e){return e&&typeof e=="object"&&!(e instanceof Array)&&!(e instanceof Date)}},yc={typeNames:["integer","number","string","array","object","boolean","null","date"],getType(t){return yc.typeNames.find(e=>zW[e](t))},mergeSchemaObjs(t,e){if(!t||!e)return null;let r=(0,yE.default)(t),n=(0,yE.default)(e);if(!mc(r,n)){if(t.type==="array"&&e.type==="array"&&mc((0,qW.default)(r,n),["items"])){let o=r.length>n.length?e:t,s=r.length>n.length?t:e;if((0,yE.default)(o).reduce((c,u)=>mc(o[u],s[u])&&c,!0))return o}if(t.type!=="object"||e.type!=="object")return null}let i={};for(let o=0,{length:s}=r;o<s;o++){let a=r[o];if(yc.getType(t[a])==="object"){let c=yc.mergeSchemaObjs(t[a],e[a]);if(c)i[a]=c;else{if(t.type==="object"||e.type==="object")return{type:"object"};if(a!=="items"||t.type!=="array"||e.type!=="array")return null}}else if(a==="type")if(t[a]!==e[a])if(t[a]==="integer"&&e[a]==="number"||t[a]==="number"&&e[a]==="integer")i[a]="number";else return null;else i[a]=t[a];else{if(!mc(t[a],e[a]))return null;i[a]=t[a]}}return i}};function GW(t){let e;for(let r=0,{length:n}=t;r<n;r++){let i=t[r];if(r>0&&(i==="integer"&&e==="number"?i="number":i==="number"&&e==="integer"&&(e="number"),e!==i))return null;e=i}return e}function YW(t){return GW(t.map(e=>yc.getType(e)))}var IE=class{constructor(e){this.options=(0,EE.default)({},HW,e),this.depth=0,this.getObjectSchemaDefault=this.getObjectSchemaDefault.bind(this),this.getStringSchemaDefault=this.getStringSchemaDefault.bind(this),this.objectPostProcessDefault=this.objectPostProcessDefault.bind(this),this.commmonPostProcessDefault=this.commmonPostProcessDefault.bind(this),this.objectPostProcessDefault=this.objectPostProcessDefault.bind(this)}getCommonArrayItemSchema(e){let r=e.map(n=>{this.depth++;let i=this.getSchema(n);return this.depth--,i});return r.reduce((n,i)=>yc.mergeSchemaObjs(n,i),r.pop())}getObjectSchemaDefault(e){let r={type:"object"},n=Object.keys(e);return n.length>0&&(r.properties=n.reduce((i,o)=>(this.depth++,i[o]=this.getSchema(e[o]),this.depth--,i),{})),r}getObjectSchema(e){return this.options.objects.preProcessFnc?this.options.objects.preProcessFnc(e,this.getObjectSchemaDefault):this.getObjectSchemaDefault(e)}getArraySchemaMerging(e){let r={type:"array"},n=YW(e);if(n)if(r.items={type:n},n!=="integer"&&n!=="number"){let i=this.getCommonArrayItemSchema(e);i&&(r.items=i)}else this.options.required&&(r.items.required=!0);return r}getArraySchemaNoMerging(e){let r={type:"array"};return e.length>0&&(this.depth++,r.items=this.getSchema(e[0]),this.depth--),r}getArraySchemaTuple(e){let r={type:"array"};return e.length>0&&(r.items=e.map(n=>{this.depth++;let i=this.getSchema(n);return this.depth--,i})),r}getArraySchemaUniform(e){let r=this.getArraySchemaNoMerging(e);if(e.length>1)for(let n=1;n<e.length;n++){this.depth++;let i=this.getSchema(e[n]);if(this.depth--,!mc(r.items,i))throw new Error("Invalid schema, incompatible array items")}return r}getArraySchema(e){if(e.length===0)return{type:"array"};switch(this.options.arrays.mode){case"all":return this.getArraySchemaMerging(e);case"first":return this.getArraySchemaNoMerging(e);case"uniform":return this.getArraySchemaUniform(e);case"tuple":return this.getArraySchemaTuple(e);default:throw new Error(`Unknown array mode option '${this.options.arrays.mode}'`)}}getStringSchemaDefault(e){return{type:"string"}}getStringSchema(e){return this.options.strings.preProcessFnc?this.options.strings.preProcessFnc(e,this.getStringSchemaDefault):this.getStringSchemaDefault(e)}commmonPostProcessDefault(e,r,n){return this.options.required&&this.depth<=this.options.requiredDepth?(0,EE.default)({},r,{required:!0}):r}objectPostProcessDefault(e,r){return this.options.objects.additionalProperties===!1&&Object.getOwnPropertyNames(r).length>0?(0,EE.default)({},e,{additionalProperties:!1}):e}getSchema(e){let r=yc.getType(e);r||(r="null");let n;switch(r){case"object":n=this.getObjectSchema(e);break;case"array":n=this.getArraySchema(e);break;case"string":n=this.getStringSchema(e);break;default:n={type:r}}return this.options.postProcessFnc?n=this.options.postProcessFnc(r,n,e,this.commmonPostProcessDefault):n=this.commmonPostProcessDefault(r,n,e),r==="object"&&(this.options.objects.postProcessFnc?n=this.options.objects.postProcessFnc(n,e,this.objectPostProcessDefault):n=this.objectPostProcessDefault(n,e)),n}};function VW(t,e){return new IE(e).getSchema(t)}function Al(t){if(!t||typeof t!="object")return t;if(Array.isArray(t))return t.map(r=>Al(r));let e={...t};if(delete e.required,e.properties&&typeof e.properties=="object"){let r=[],n={};for(let[i,o]of Object.entries(e.properties)){let s=o;if(s&&typeof s=="object"&&s.required===!0){r.push(i);let{required:a,...c}=s;n[i]=Al(c)}else n[i]=Al(s)}e.properties=n,r.length>0&&(e.required=r)}return e.items&&(e.items=Al(e.items)),e}function pl(t){if(!t||typeof t!="object")return null;if(t.const!==void 0)return t.const;if(t.enum&&Array.isArray(t.enum)&&t.enum.length>0)return t.enum[0];if(t.default!==void 0)return t.default;if(t.oneOf&&Array.isArray(t.oneOf)&&t.oneOf.length>0)return pl(t.oneOf[0]);if(t.anyOf&&Array.isArray(t.anyOf)&&t.anyOf.length>0)return pl(t.anyOf[0]);switch(Array.isArray(t.type)?t.type[0]:t.type){case"string":case"number":case"integer":case"boolean":return null;case"null":return null;case"array":return t.items?[]:[];case"object":let r={};if(t.properties&&typeof t.properties=="object"){let n=t.required||[];for(let[i,o]of Object.entries(t.properties))r[i]=pl(o)}return r;default:if(t.properties&&typeof t.properties=="object"){let n={};for(let[i,o]of Object.entries(t.properties))n[i]=pl(o);return n}return null}}function ep(t){if(typeof t!="string")return t;try{return JSON.parse(t)}catch{return t}}function JW(t){let e={...t};return e.inputSchema&&(e.inputSchema=ep(e.inputSchema)),e.outputSchema&&(e.outputSchema=ep(e.outputSchema)),e.responseSchema&&(e.responseSchema=ep(e.responseSchema)),e}});var Br=g(M=>{"use strict";Object.defineProperty(M,"__esModule",{value:!0});M.PLAYBOOK_LIMITS=M.MCP_SERVER_AUTH_MODES=M.OAUTH_POPUP_CLOSED_MESSAGE=M.OAUTH_CONTINUATION_REASON_MAX_CHARS=M.AGENT_REQUEST_BUSY_STATUSES=M.AGENT_SESSION_USER_OPENED_METADATA_KEY=M.AGENT_SESSION_RESOURCE_KINDS=M.AGENT_MESSAGE_SCHEMA_VERSION=M.AGENT_APPROVAL_MODES=M.ConfirmationAction=M.LOADABLE_MARKDOWN_NAMES=M.SKILL_REFERENCE_NAMES=M.SKILL_BODY_NAMES=M.AGENT_CHECKLIST_MAX_LABEL_CHARS=M.AGENT_CHECKLIST_MAX_ITEMS=M.AGENT_CHECKLIST_MIN_ITEMS=M.DYNAMIC_AGENT_TOOLS=M.AGENT_TOOLS=M.AGENT_NATIVE_TOOLS=M.PLAYBOOK_PLAYGROUND_DRAFT_ID=M.PLAYGROUND_TOOL_DRAFT_ID=M.AgentType=M.FileStatus=M.MAX_BULK_RESOURCE_SHARE_OPERATIONS=M.MAX_BULK_MUTATION_IDS=M.SERVER_MANAGED_CONFIG_FIELDS=M.RunExecutionKind=M.RequestSource=M.RunStatus=M.CredentialMode=M.UpsertMode=M.LogLevel=M.PaginationType=M.DecompressionMethod=M.AuthType=M.FileType=M.CacheMode=M.HttpMethod=M.SupportedFileType=M.RUN_COMMAND_EFFECT_KINDS=M.CONNECTION_PROTOCOLS=void 0;M.isRequestConfig=WW;M.isTransformConfig=ZW;M.isAgentSessionOpenedByUser=KW;M.CONNECTION_PROTOCOLS=["http","postgres","mssql","redis","mongodb","sftp","smb","odbc","script","suitecloud"];M.RUN_COMMAND_EFFECT_KINDS=["tool","tool_state","system","project","schedule","session","briefing","mcp_server","role","playbook","artifact","share","org_settings","file","memory"];var U_;(function(t){t.JSON="JSON",t.CSV="CSV",t.XML="XML",t.HTML="HTML",t.YAML="YAML",t.EXCEL="EXCEL",t.PDF="PDF",t.DOCX="DOCX",t.PPTX="PPTX",t.ZIP="ZIP",t.GZIP="GZIP",t.BINARY="BINARY",t.RAW="RAW",t.AUTO="AUTO"})(U_||(M.SupportedFileType=U_={}));var M_;(function(t){t.GET="GET",t.POST="POST",t.PUT="PUT",t.DELETE="DELETE",t.PATCH="PATCH",t.HEAD="HEAD",t.OPTIONS="OPTIONS"})(M_||(M.HttpMethod=M_={}));var x_;(function(t){t.ENABLED="ENABLED",t.READONLY="READONLY",t.WRITEONLY="WRITEONLY",t.DISABLED="DISABLED"})(x_||(M.CacheMode=x_={}));var L_;(function(t){t.CSV="CSV",t.JSON="JSON",t.XML="XML",t.YAML="YAML",t.EXCEL="EXCEL",t.HTML="HTML",t.PDF="PDF",t.DOCX="DOCX",t.PPTX="PPTX",t.ZIP="ZIP",t.BINARY="BINARY",t.RAW="RAW",t.AUTO="AUTO"})(L_||(M.FileType=L_={}));var P_;(function(t){t.NONE="NONE",t.OAUTH2="OAUTH2",t.HEADER="HEADER",t.QUERY_PARAM="QUERY_PARAM"})(P_||(M.AuthType=P_={}));var F_;(function(t){t.GZIP="GZIP",t.DEFLATE="DEFLATE",t.NONE="NONE",t.AUTO="AUTO",t.ZIP="ZIP"})(F_||(M.DecompressionMethod=F_={}));var $_;(function(t){t.OFFSET_BASED="OFFSET_BASED",t.PAGE_BASED="PAGE_BASED",t.CURSOR_BASED="CURSOR_BASED",t.DISABLED="DISABLED"})($_||(M.PaginationType=$_={}));var j_;(function(t){t.DEBUG="DEBUG",t.INFO="INFO",t.WARN="WARN",t.ERROR="ERROR"})(j_||(M.LogLevel=j_={}));var q_;(function(t){t.CREATE="CREATE",t.UPDATE="UPDATE",t.UPSERT="UPSERT"})(q_||(M.UpsertMode=q_={}));var H_;(function(t){t.MERGE="MERGE",t.REPLACE="REPLACE"})(H_||(M.CredentialMode=H_={}));var z_;(function(t){t.RUNNING="RUNNING",t.SUCCESS="SUCCESS",t.FAILED="FAILED",t.ABORTED="ABORTED"})(z_||(M.RunStatus=z_={}));var G_;(function(t){t.API="api",t.FRONTEND="frontend",t.AGENT="agent",t.SCHEDULER="scheduler",t.MCP="mcp",t.TOOL_CHAIN="tool-chain",t.WEBHOOK="webhook",t.CLI="cli"})(G_||(M.RequestSource=G_={}));var Y_;(function(t){t.FULL="full",t.DRAFT="draft",t.SINGLE_STEP="single-step"})(Y_||(M.RunExecutionKind=Y_={}));M.SERVER_MANAGED_CONFIG_FIELDS=["version","createdByUserId","createdAt","updatedAt","lastUsedAt"];M.MAX_BULK_MUTATION_IDS=100;M.MAX_BULK_RESOURCE_SHARE_OPERATIONS=1e3;function WW(t){return!t||typeof t!="object"?!1:t.type==="request"||!("type"in t)||t.type===void 0}function ZW(t){return t?.type==="transform"}var V_;(function(t){t.PENDING="PENDING",t.UPLOADING="UPLOADING",t.PROCESSING="PROCESSING",t.COMPLETED="COMPLETED",t.FAILED="FAILED"})(V_||(M.FileStatus=V_={}));var ts;(function(t){t.MAIN="main",t.PLAYGROUND="playground",t.SYSTEM_PLAYGROUND="system_playground",t.PLAYBOOK_PLAYGROUND="playbook_playground",t.ARTIFACT_PLAYGROUND="artifact_playground",t.ACCESS_RULES="access_rules"})(ts||(M.AgentType=ts={}));M.PLAYGROUND_TOOL_DRAFT_ID="@playground-draft";M.PLAYBOOK_PLAYGROUND_DRAFT_ID="@playground-draft";M.AGENT_NATIVE_TOOLS=["run_command","load_skill","use_checklist","set_credentials","authenticate_oauth","setup_gateway"];M.AGENT_TOOLS={[ts.MAIN]:[...M.AGENT_NATIVE_TOOLS],[ts.PLAYGROUND]:[...M.AGENT_NATIVE_TOOLS],[ts.SYSTEM_PLAYGROUND]:[...M.AGENT_NATIVE_TOOLS],[ts.PLAYBOOK_PLAYGROUND]:[...M.AGENT_NATIVE_TOOLS],[ts.ARTIFACT_PLAYGROUND]:[...M.AGENT_NATIVE_TOOLS],[ts.ACCESS_RULES]:[...M.AGENT_NATIVE_TOOLS]};M.DYNAMIC_AGENT_TOOLS=["web_search"];M.AGENT_CHECKLIST_MIN_ITEMS=4;M.AGENT_CHECKLIST_MAX_ITEMS=15;M.AGENT_CHECKLIST_MAX_LABEL_CHARS=120;M.SKILL_BODY_NAMES=["superglue-info","tools","systems","access-management","tool-deployment","notifications","artifacts","playbooks","projects","superglue-brain","email","workspace-apps","meetings","brand-guidelines","demos"];M.SKILL_REFERENCE_NAMES=["http","graphql","postgres","mssql","odbc","redis","mongodb","sftp-smb","suitecloud","tool-files","tunnel-handling"];M.LOADABLE_MARKDOWN_NAMES=[...M.SKILL_BODY_NAMES,...M.SKILL_REFERENCE_NAMES];var J_;(function(t){t.CONFIRMED="confirmed",t.DECLINED="declined",t.OAUTH_SUCCESS="oauth_success",t.OAUTH_FAILURE="oauth_failure"})(J_||(M.ConfirmationAction=J_={}));M.AGENT_APPROVAL_MODES=["ask","act"];M.AGENT_MESSAGE_SCHEMA_VERSION=1;M.AGENT_SESSION_RESOURCE_KINDS=["tool","system","playbook","artifact","briefing"];M.AGENT_SESSION_USER_OPENED_METADATA_KEY="userOpened";function KW(t){return t[M.AGENT_SESSION_USER_OPENED_METADATA_KEY]===!0}M.AGENT_REQUEST_BUSY_STATUSES=["queued","claimed","running","cancelling"];M.OAUTH_CONTINUATION_REASON_MAX_CHARS=500;M.OAUTH_POPUP_CLOSED_MESSAGE="OAuth authentication did not complete.";M.MCP_SERVER_AUTH_MODES=["oauth","creator_api_key"];M.PLAYBOOK_LIMITS={name:120,whenToRun:500,inputs:25e3,instructions:1e5,completionCriteria:25e3,systemRefs:10,toolRefs:25,credentialRefs:10,fileRefs:15,compiledRender:512e3}});var XW,Z_,W_,e4,t4,r4,n4,K_=He(()=>{"use strict";XW=t=>{let e=W_(t,0);if(e===void 0||!t4(t[e]))return;let r=W_(t,e+1);if(r!==void 0)return r4(t,e,r)},Z_=XW,W_=(t,e)=>{for(let r=e;r<t.length;r+=1){let n=t[r];if(!e4(n))return r}},e4=t=>t===" "||t===" "||t===`
|
|
3
3
|
`||t==="\r",t4=t=>t==="{"||t==="[",r4=(t,e,r)=>{let n;for(let i=r-1;i>e;i-=1){let o=t[i];if(o==="\r")return;if(o===`
|
|
4
4
|
`)return n4(n);if(n===void 0)n=o;else if(n[0]===o)n+=o;else return}},n4=t=>t===void 0?0:t[0]===" "?t.length:t});var X_,bE,i4,o4,e0=He(()=>{"use strict";X_=(t,e)=>{let r=bE(t,"toPrecision",e,e);return r===void 0?bE(t,"toExponential",e,e):r},bE=(t,e,r,n)=>{let o=t[e](n).replace(i4,"$1").replace(o4,"$1");return o.length<=r?o:n===1?void 0:bE(t,e,r,n-1)},i4=/(e)\+/iu,o4=/\.?0*($|e)/iu});var r0,s4,a4,t0,n0=He(()=>{"use strict";r0=(t,e)=>{if(typeof t!="string")throw new TypeError(`Input must be a JSON string: ${t}`);s4(e)},s4=t=>{if(a4(t),t<0)throw new TypeError(`"maxSize" argument must be positive: ${t}`);if(t<t0)throw new TypeError(`"maxSize" argument must be at least ${t0}: ${t}`)},a4=t=>{if(t===void 0)throw new TypeError('"maxSize" argument must be defined');if(!Number.isInteger(t))throw new TypeError(`"maxSize" argument must be an integer: ${t}`)},t0=7});var rp,i0,np,c4,u4,l4,d4,o0,A4,p4,f4,h4,g4,m4,SE=He(()=>{"use strict";rp=(t,e,r)=>{let n=o0(e,r);return i0(t,e,n)},i0=(t,e,r)=>{if(r>=e)return r;let n=t[r];return n>=g4&&n<=m4?i0(t,e,r+1):r},np=(t,e,r)=>{if(r===void 0)return r;let n=o0(e,r);return c4(t,n)},c4=(t,e)=>u4(t,e)?e-3:l4(t,e)?e-2:d4(t,e)?e-1:e,u4=(t,e)=>e>=3&&t[e-3]>=A4&&t[e-3]<=p4,l4=(t,e)=>e>=2&&t[e-2]>=f4,d4=(t,e)=>e>=1&&t[e-1]>=h4,o0=(t,e)=>e<0||Object.is(e,-0)?Math.max(t+e,0):e,A4=240,p4=244,f4=224,h4=194,g4=128,m4=191});var s0,a0=He(()=>{"use strict";SE();s0=(t,e,r)=>{let n=globalThis.Buffer.from(t),i=rp(n,n.length,e),o=np(n,n.length,r);return i===0&&o>=n.length?n.toString():n.toString("utf8",i,o)}});var c0,u0=He(()=>{"use strict";c0=/[\uD800-\uDFFF]/gu});var ip,E4,QE=He(()=>{"use strict";u0();ip=t=>E4(t)?t.replace(c0,"\uFFFD"):t,E4=t=>{for(let e=0;e<t.length;e+=1){let r=t.codePointAt(e);if(r>=55296&&r<=57343)return!0}return!1}});var vE,l0=He(()=>{"use strict";vE=({input:t,targetByteCount:e,firstStartSurrogate:r,lastStartSurrogate:n,firstEndSurrogate:i,lastEndSurrogate:o,increment:s,canBacktrack:a,shift:c,charIndexInit:u})=>{let l=u,d=l,A=0;for(;A<e;l+=s){d=l;let h=t.charCodeAt(l);if(Number.isNaN(h))break;if(h<=127){A+=1;continue}if(h<=2047){A+=2;continue}if(A+=3,h<r||h>n)continue;let I=t.charCodeAt(l+s);Number.isNaN(I)||I<i||I>o||(A+=1,l+=s)}return(a&&A>e?d:l)+c}});var _E,B4,w4,d0=He(()=>{"use strict";l0();_E=(t,e,r)=>e<0||Object.is(e,-0)?w4(t,e,r):B4(t,e,r),B4=(t,e,r)=>vE({input:t,targetByteCount:e,firstStartSurrogate:55296,lastStartSurrogate:56319,firstEndSurrogate:56320,lastEndSurrogate:57343,increment:1,canBacktrack:r,shift:0,charIndexInit:0}),w4=(t,e,r)=>vE({input:t,targetByteCount:-e,firstStartSurrogate:56320,lastStartSurrogate:57343,firstEndSurrogate:55296,lastEndSurrogate:56319,increment:-1,canBacktrack:!r,shift:1,charIndexInit:t.length-1})});var op,Q4,A0=He(()=>{"use strict";QE();d0();op=(t,e,r)=>{let n=_E(t,e,!1),i=Q4(t,r),o=n===0&&i===void 0?t:t.slice(n,i);return ip(o)},Q4=(t,e)=>{if(e===void 0)return e;let r=_E(t,e,!0);return r===t.length?void 0:r}});var f0,v4,DE,p0,_4,D4,sp,h0=He(()=>{"use strict";SE();f0=(t,e,r)=>{let{textEncoder:n,textDecoder:i}=v4(),o=_4(t),{written:s}=n.encodeInto(t,o),a=rp(o,s,e),c=np(o,s,r),u=c===void 0?s:Math.min(c,s),l=o.subarray(a,u);return i.decode(l)},v4=()=>(DE===void 0&&(DE=new globalThis.TextEncoder,p0=new globalThis.TextDecoder("utf8",{fatal:!1})),{textEncoder:DE,textDecoder:p0}),_4=t=>{let e=t.length*3;return e>D4?new Uint8Array(e):((sp===void 0||sp.length<e)&&(sp=new Uint8Array(e)),sp)},D4=1e5});var g0,TE,m0,y0=He(()=>{"use strict";g0=(t,e)=>{if(e===void 0)return e;let r=TE(t,e);return r>=t.length*m0?void 0:r},TE=(t,e)=>e<=t.length*-m0?0:e,m0=4});var E0,T4,R4,I0,C0=He(()=>{"use strict";E0=(t,e,r)=>{if(typeof t!="string")throw new TypeError(`First argument must be a string: ${t}`);T4(e),R4(r)},T4=t=>{if(t===void 0)throw new TypeError("Second argument is required.");I0("Second",t)},R4=t=>{t!==void 0&&I0("Third",t)},I0=(t,e)=>{if(!Number.isInteger(e))throw new TypeError(`${t} argument must be an integer: ${e}`)}});var b0,N4,RE,S0=He(()=>{"use strict";b0=t=>{let e=!0,r=0;for(let n=0;n<RE;n+=1){let i=N4(t,n);i<=127||(e&&(e=!1),i>2047&&(r+=1))}return{asciiOnly:e,longCharsPercentage:r/RE}},N4=(t,e)=>{let r=RE-1,n=1-(r-e)/r,i=Math.round(n*(t.length-1));return t.charCodeAt(i)},RE=50});var k4,B0,O4,U4,M4,x4,w0,Q0=He(()=>{"use strict";a0();A0();h0();y0();QE();C0();S0();k4=(t,e,r)=>{if(E0(t,e,r),t==="")return t;let n=TE(t,e),i=g0(t,r);return i===void 0&&Object.is(n,0)?ip(t):O4(t,n,i)},B0=k4,O4=(t,e,r)=>{if(t.length<=U4)return op(t,e,r);let{asciiOnly:n,longCharsPercentage:i}=b0(t);return n?x4(t,e,r):i>=M4?op(t,e,r):w0(t,e,r)},U4=200,M4=.4,x4=(t,e,r)=>"Buffer"in globalThis&&"from"in globalThis.Buffer?s0(t,e,r):w0(t,e,r),w0=(t,e,r)=>"TextEncoder"in globalThis?f0(t,e,r):op(t,e,r)});var _0,L4,P4,F4,$4,fl,v0,D0=He(()=>{"use strict";Q0();_0=(t,e)=>{let r=JSON.stringify(t),n=F4(r),i=B0(n,0,e-v0.length-fl.length*2),s=`${L4(i)}${v0}`;return $4(s)},L4=t=>t.replace(P4,""),P4=/(\\|\\u[0-9a-fA-F]{0,3})$/u,F4=t=>t.slice(fl.length,-fl.length),$4=t=>`${fl}${t}${fl}`,fl='"',v0="..."});var T0,R0=He(()=>{"use strict";T0=t=>globalThis.Buffer.byteLength(t)});var NE,j4,q4,H4,z4,G4,Y4,N0=He(()=>{"use strict";NE=t=>{let e=t.length,r=e;for(let n=0;n<e;n+=1){let i=t.charCodeAt(n);if(i<=j4)continue;if(i<=q4){r+=1;continue}if(r+=2,i<H4||i>z4)continue;let o=t.charCodeAt(n+1);o<G4||o>Y4||(n+=1)}return r},j4=127,q4=2047,H4=55296,z4=56319,G4=56320,Y4=57343});var k0,V4,J4,W4,ap,O0=He(()=>{"use strict";k0=()=>V4.bind(void 0,new TextEncoder),V4=(t,e)=>{let r=J4(e);return t.encodeInto(e,r).written},J4=t=>{let e=t.length*3;return e>W4?new Uint8Array(e):((ap===void 0||ap.length<e)&&(ap=new Uint8Array(e)),ap)},W4=1e5});var K4,X4,U0,M0=He(()=>{"use strict";R0();N0();O0();K4=()=>"Buffer"in globalThis&&"byteLength"in globalThis.Buffer?T0:"TextEncoder"in globalThis?X4.bind(void 0,k0()):NE,X4=(t,e)=>e.length<100?NE(e):t(e),U0=K4()});var x0,eZ,tZ,rZ,nZ,kE,L0=He(()=>{"use strict";M0();x0=t=>{if(t===null)return eZ;if(t===!0)return tZ;if(t===!1)return rZ;let e=typeof t;return e==="object"?nZ:e==="number"?JSON.stringify(t).length:kE(t)},eZ=4,tZ=4,rZ=5,nZ=2,kE=t=>U0(JSON.stringify(t))});var cp,F0,$0,j0,iZ,q0,P0,H0,oZ,hl=He(()=>{"use strict";L0();cp=({size:t,increment:e,maxSize:r,truncatedProps:n,path:i,value:o})=>{let s=t+e,a=s>r;return a?{size:t,stop:a,truncatedProps:[...n,{path:i,value:o}]}:{size:s,stop:a,truncatedProps:n}},F0=t=>x0(t),$0=(t,e,r)=>{let n=q0({empty:t,indent:e,depth:r,keySpaceSize:0}),i=H0(t);return n+i},j0=({key:t,empty:e,indent:r,depth:n})=>{let i=q0({empty:e,indent:r,depth:n,keySpaceSize:1}),o=kE(t),s=H0(e);return i+o+iZ+s},iZ=1,q0=({empty:t,indent:e,depth:r,keySpaceSize:n})=>{if(e===void 0)return 0;let i=P0+e*(r+1),o=t?P0+e*r:0;return n+i+o},P0=1,H0=t=>t?0:oZ,oZ=1});var up,sZ,OE=He(()=>{"use strict";hl();up=({parent:t,truncatedProps:e,path:r,increment:n,maxSize:i,key:o,empty:s,size:a,truncateValue:c,indent:u,depth:l})=>{let d=t[o],A=[...r,o],{size:p,stop:h,truncatedProps:I}=cp({size:a,increment:n,maxSize:i,truncatedProps:e,path:A,value:d});return h?{empty:s,size:p,truncatedProps:I}:sZ({value:d,truncatedProps:e,path:A,maxSize:i,empty:s,size:a,newSize:p,truncateValue:c,indent:u,depth:l})},sZ=({value:t,truncatedProps:e,path:r,maxSize:n,empty:i,size:o,newSize:s,truncateValue:a,indent:c,depth:u})=>{let{value:l,size:d,truncatedProps:A}=a({value:t,truncatedProps:e,path:r,size:s,maxSize:n,indent:c,depth:u+1});return l===void 0?{empty:i,size:o,truncatedProps:A}:{empty:!1,size:d,value:l,truncatedProps:A}}});var z0,G0=He(()=>{"use strict";OE();hl();z0=({array:t,truncatedProps:e,path:r,size:n,maxSize:i,truncateValue:o,indent:s,depth:a})=>{let c=[],u={empty:!0,size:n,truncatedProps:e};for(let l=0;l<t.length;l+=1){let d=$0(u.empty,s,a);u=up({parent:t,truncatedProps:u.truncatedProps,path:r,increment:d,maxSize:i,key:l,empty:u.empty,size:u.size,truncateValue:o,indent:s,depth:a}),u.value!==void 0&&c.push(u.value)}return{value:c,size:u.size,truncatedProps:u.truncatedProps}}});var Y0,V0=He(()=>{"use strict";OE();hl();Y0=({object:t,truncatedProps:e,path:r,size:n,maxSize:i,truncateValue:o,indent:s,depth:a})=>{let c={},u={empty:!0,size:n,truncatedProps:e};for(let l in t){let d=j0({key:l,empty:u.empty,indent:s,depth:a});u=up({parent:t,truncatedProps:u.truncatedProps,path:r,increment:d,maxSize:i,key:l,empty:u.empty,size:u.size,truncateValue:o,indent:s,depth:a}),u.value!==void 0&&(c[l]=u.value)}return{value:c,size:u.size,truncatedProps:u.truncatedProps}}});var lp,aZ,J0=He(()=>{"use strict";G0();V0();hl();lp=({value:t,truncatedProps:e,path:r,size:n,maxSize:i,indent:o,depth:s})=>{let a=F0(t),{size:c,stop:u,truncatedProps:l}=cp({size:n,increment:a,maxSize:i,truncatedProps:e,path:r,value:t});return u?{value:void 0,size:c,truncatedProps:l}:aZ({value:t,truncatedProps:l,path:r,size:c,maxSize:i,indent:o,depth:s})},aZ=({value:t,truncatedProps:e,path:r,size:n,maxSize:i,indent:o,depth:s})=>typeof t!="object"||t===null?{value:t,size:n,truncatedProps:e}:Array.isArray(t)?z0({array:t,truncatedProps:e,path:r,size:n,maxSize:i,truncateValue:lp,indent:o,depth:s}):Y0({object:t,truncatedProps:e,path:r,size:n,maxSize:i,truncateValue:lp,indent:o,depth:s})});var W0={};Pv(W0,{default:()=>uZ});var cZ,uZ,lZ,dZ,AZ,Z0=He(()=>{"use strict";K_();e0();n0();D0();J0();cZ=(t,e)=>{r0(t,e);let r=lZ(t),n=dZ(t),{value:i,truncatedProps:o}=lp({value:n,truncatedProps:[],path:[],size:0,maxSize:e,indent:r,depth:0});return{jsonString:AZ({newValue:i,value:n,maxSize:e,indent:r}),truncatedProps:o}},uZ=cZ,lZ=t=>{let e=Z_(t);return typeof e=="string"?e.length:e},dZ=t=>{try{return JSON.parse(t)}catch(e){throw new TypeError(`Invalid JSON string: "${t}"
|
|
5
5
|
${e.message}`)}},AZ=({newValue:t,value:e,maxSize:r,indent:n})=>t!==void 0?JSON.stringify(t,void 0,n):typeof e=="number"?X_(e,r):_0(e,r)});var X0=g(K0=>{"use strict";Object.defineProperty(K0,"__esModule",{value:!0})});var rs=g(dp=>{"use strict";Object.defineProperty(dp,"__esModule",{value:!0});dp.CronField=void 0;var UE=class t{#e=!1;#t=!1;#n=!1;#i=[];options={rawValue:""};static get min(){throw new Error("min must be overridden")}static get max(){throw new Error("max must be overridden")}static get chars(){return Object.freeze([])}static get validChars(){return/^[?,*\dH/-]+$|^.*H\(\d+-\d+\)\/\d+.*$|^.*H\(\d+-\d+\).*$|^.*H\/\d+.*$/}static get constraints(){return{min:this.min,max:this.max,chars:this.chars,validChars:this.validChars}}constructor(e,r={rawValue:""}){if(!Array.isArray(e))throw new Error(`${this.constructor.name} Validation error, values is not an array`);if(!(e.length>0))throw new Error(`${this.constructor.name} Validation error, values contains no values`);this.options={...r,rawValue:r.rawValue??""},this.#i=e.sort(t.sorter),this.#n=this.options.wildcard!==void 0?this.options.wildcard:this.#o(),this.#e=this.options.rawValue.includes("L")||e.includes("L"),this.#t=this.options.rawValue.includes("?")||e.includes("?")}get min(){return this.constructor.min}get max(){return this.constructor.max}get chars(){return this.constructor.chars}get hasLastChar(){return this.#e}get hasQuestionMarkChar(){return this.#t}get isWildcard(){return this.#n}get values(){return this.#i}static sorter(e,r){let n=typeof e=="number",i=typeof r=="number";return n&&i?e-r:!n&&!i?e.localeCompare(r):n?-1:1}static findNearestValueInList(e,r,n=!1){if(n){for(let i=e.length-1;i>=0;i--)if(e[i]<r)return e[i];return null}for(let i=0;i<e.length;i++)if(e[i]>r)return e[i];return null}findNearestValue(e,r=!1){return this.constructor.findNearestValueInList(this.values,e,r)}serialize(){return{wildcard:this.#n,values:this.#i}}validate(){let e,r=this.chars.length>0?` or chars ${this.chars.join("")}`:"",n=a=>c=>new RegExp(`^\\d{0,2}${c}$`).test(a),i=a=>(e=a,typeof a=="number"?a>=this.min&&a<=this.max:this.chars.some(n(a)));if(!this.#i.every(i))throw new Error(`${this.constructor.name} Validation error, got value ${e} expected range ${this.min}-${this.max}${r}`);let s=this.#i.find((a,c)=>this.#i.indexOf(a)!==c);if(s)throw new Error(`${this.constructor.name} Validation error, duplicate values found: ${s}`)}#o(){return this.options.rawValue.length>0?["*","?"].includes(this.options.rawValue):Array.from({length:this.max-this.min+1},(e,r)=>r+this.min).every(e=>this.#i.includes(e))}};dp.CronField=UE});var eD=g(Ap=>{"use strict";Object.defineProperty(Ap,"__esModule",{value:!0});Ap.CronDayOfMonth=void 0;var pZ=rs(),fZ=1,hZ=31,gZ=Object.freeze(["L"]),ME=class extends pZ.CronField{static get min(){return fZ}static get max(){return hZ}static get chars(){return gZ}static get validChars(){return/^[?,*\dLH/-]+$|^.*H\(\d+-\d+\)\/\d+.*$|^.*H\(\d+-\d+\).*$|^.*H\/\d+.*$/}constructor(e,r){super(e,r),this.validate()}get values(){return super.values}};Ap.CronDayOfMonth=ME});var tD=g(pp=>{"use strict";Object.defineProperty(pp,"__esModule",{value:!0});pp.CronDayOfWeek=void 0;var mZ=rs(),yZ=0,EZ=7,IZ=Object.freeze(["L"]),xE=class extends mZ.CronField{static get min(){return yZ}static get max(){return EZ}static get chars(){return IZ}static get validChars(){return/^[?,*\dLH#/-]+$|^.*H\(\d+-\d+\)\/\d+.*$|^.*H\(\d+-\d+\).*$|^.*H\/\d+.*$/}constructor(e,r){super(e,r),this.validate()}get values(){return super.values}get nthDay(){return this.options.nthDayOfWeek??0}};pp.CronDayOfWeek=xE});var rD=g(fp=>{"use strict";Object.defineProperty(fp,"__esModule",{value:!0});fp.CronHour=void 0;var CZ=rs(),bZ=0,SZ=23,BZ=Object.freeze([]),LE=class extends CZ.CronField{static get min(){return bZ}static get max(){return SZ}static get chars(){return BZ}constructor(e,r){super(e,r),this.validate()}get values(){return super.values}};fp.CronHour=LE});var nD=g(hp=>{"use strict";Object.defineProperty(hp,"__esModule",{value:!0});hp.CronMinute=void 0;var wZ=rs(),QZ=0,vZ=59,_Z=Object.freeze([]),PE=class extends wZ.CronField{static get min(){return QZ}static get max(){return vZ}static get chars(){return _Z}constructor(e,r){super(e,r),this.validate()}get values(){return super.values}};hp.CronMinute=PE});var kT=g(Dr=>{"use strict";Object.defineProperty(Dr,"__esModule",{value:!0});var Io=class extends Error{},JE=class extends Io{constructor(e){super(`Invalid DateTime: ${e.toMessage()}`)}},WE=class extends Io{constructor(e){super(`Invalid Interval: ${e.toMessage()}`)}},ZE=class extends Io{constructor(e){super(`Invalid Duration: ${e.toMessage()}`)}},os=class extends Io{},Sp=class extends Io{constructor(e){super(`Invalid unit ${e}`)}},_t=class extends Io{},jn=class extends Io{constructor(){super("Zone is an abstract class")}},j="numeric",Qn="short",vr="long",Bp={year:j,month:j,day:j},OD={year:j,month:Qn,day:j},DZ={year:j,month:Qn,day:j,weekday:Qn},UD={year:j,month:vr,day:j},MD={year:j,month:vr,day:j,weekday:vr},xD={hour:j,minute:j},LD={hour:j,minute:j,second:j},PD={hour:j,minute:j,second:j,timeZoneName:Qn},FD={hour:j,minute:j,second:j,timeZoneName:vr},$D={hour:j,minute:j,hourCycle:"h23"},jD={hour:j,minute:j,second:j,hourCycle:"h23"},qD={hour:j,minute:j,second:j,hourCycle:"h23",timeZoneName:Qn},HD={hour:j,minute:j,second:j,hourCycle:"h23",timeZoneName:vr},zD={year:j,month:j,day:j,hour:j,minute:j},GD={year:j,month:j,day:j,hour:j,minute:j,second:j},YD={year:j,month:Qn,day:j,hour:j,minute:j},VD={year:j,month:Qn,day:j,hour:j,minute:j,second:j},TZ={year:j,month:Qn,day:j,weekday:Qn,hour:j,minute:j},JD={year:j,month:vr,day:j,hour:j,minute:j,timeZoneName:Qn},WD={year:j,month:vr,day:j,hour:j,minute:j,second:j,timeZoneName:Qn},ZD={year:j,month:vr,day:j,weekday:vr,hour:j,minute:j,timeZoneName:vr},KD={year:j,month:vr,day:j,weekday:vr,hour:j,minute:j,second:j,timeZoneName:vr},as=class{get type(){throw new jn}get name(){throw new jn}get ianaName(){return this.name}get isUniversal(){throw new jn}offsetName(e,r){throw new jn}formatOffset(e,r){throw new jn}offset(e){throw new jn}equals(e){throw new jn}get isValid(){throw new jn}},FE=null,Cl=class t extends as{static get instance(){return FE===null&&(FE=new t),FE}get type(){return"system"}get name(){return new Intl.DateTimeFormat().resolvedOptions().timeZone}get isUniversal(){return!1}offsetName(e,{format:r,locale:n}){return uT(e,r,n)}formatOffset(e,r){return Il(this.offset(e),r)}offset(e){return-new Date(e).getTimezoneOffset()}equals(e){return e.type==="system"}get isValid(){return!0}},KE=new Map;function RZ(t){let e=KE.get(t);return e===void 0&&(e=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:t,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",era:"short"}),KE.set(t,e)),e}var NZ={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};function kZ(t,e){let r=t.format(e).replace(/\u200E/g,""),n=/(\d+)\/(\d+)\/(\d+) (AD|BC),? (\d+):(\d+):(\d+)/.exec(r),[,i,o,s,a,c,u,l]=n;return[s,i,o,a,c,u,l]}function OZ(t,e){let r=t.formatToParts(e),n=[];for(let i=0;i<r.length;i++){let{type:o,value:s}=r[i],a=NZ[o];o==="era"?n[a]=s:pe(a)||(n[a]=parseInt(s,10))}return n}var $E=new Map,Co=class t extends as{static create(e){let r=$E.get(e);return r===void 0&&$E.set(e,r=new t(e)),r}static resetCache(){$E.clear(),KE.clear()}static isValidSpecifier(e){return this.isValidZone(e)}static isValidZone(e){if(!e)return!1;try{return new Intl.DateTimeFormat("en-US",{timeZone:e}).format(),!0}catch{return!1}}constructor(e){super(),this.zoneName=e,this.valid=t.isValidZone(e)}get type(){return"iana"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(e,{format:r,locale:n}){return uT(e,r,n,this.name)}formatOffset(e,r){return Il(this.offset(e),r)}offset(e){if(!this.valid)return NaN;let r=new Date(e);if(isNaN(r))return NaN;let n=RZ(this.name),[i,o,s,a,c,u,l]=n.formatToParts?OZ(n,r):kZ(n,r);a==="BC"&&(i=-Math.abs(i)+1);let A=Rp({year:i,month:o,day:s,hour:c===24?0:c,minute:u,second:l,millisecond:0}),p=+r,h=p%1e3;return p-=h>=0?h:1e3+h,(A-p)/(60*1e3)}equals(e){return e.type==="iana"&&e.name===this.name}get isValid(){return this.valid}},iD={};function UZ(t,e={}){let r=JSON.stringify([t,e]),n=iD[r];return n||(n=new Intl.ListFormat(t,e),iD[r]=n),n}var XE=new Map;function eI(t,e={}){let r=JSON.stringify([t,e]),n=XE.get(r);return n===void 0&&(n=new Intl.DateTimeFormat(t,e),XE.set(r,n)),n}var tI=new Map;function MZ(t,e={}){let r=JSON.stringify([t,e]),n=tI.get(r);return n===void 0&&(n=new Intl.NumberFormat(t,e),tI.set(r,n)),n}var rI=new Map;function xZ(t,e={}){let{base:r,...n}=e,i=JSON.stringify([t,n]),o=rI.get(i);return o===void 0&&(o=new Intl.RelativeTimeFormat(t,e),rI.set(i,o)),o}var ml=null;function LZ(){return ml||(ml=new Intl.DateTimeFormat().resolvedOptions().locale,ml)}var nI=new Map;function XD(t){let e=nI.get(t);return e===void 0&&(e=new Intl.DateTimeFormat(t).resolvedOptions(),nI.set(t,e)),e}var iI=new Map;function PZ(t){let e=iI.get(t);if(!e){let r=new Intl.Locale(t);e="getWeekInfo"in r?r.getWeekInfo():r.weekInfo,"minimalDays"in e||(e={...eT,...e}),iI.set(t,e)}return e}function FZ(t){let e=t.indexOf("-x-");e!==-1&&(t=t.substring(0,e));let r=t.indexOf("-u-");if(r===-1)return[t];{let n,i;try{n=eI(t).resolvedOptions(),i=t}catch{let c=t.substring(0,r);n=eI(c).resolvedOptions(),i=c}let{numberingSystem:o,calendar:s}=n;return[i,o,s]}}function $Z(t,e,r){return(r||e)&&(t.includes("-u-")||(t+="-u"),r&&(t+=`-ca-${r}`),e&&(t+=`-nu-${e}`)),t}function jZ(t){let e=[];for(let r=1;r<=12;r++){let n=Xe.utc(2009,r,1);e.push(t(n))}return e}function qZ(t){let e=[];for(let r=1;r<=7;r++){let n=Xe.utc(2016,11,13+r);e.push(t(n))}return e}function gp(t,e,r,n){let i=t.listingMode();return i==="error"?null:i==="en"?r(e):n(e)}function HZ(t){return t.numberingSystem&&t.numberingSystem!=="latn"?!1:t.numberingSystem==="latn"||!t.locale||t.locale.startsWith("en")||XD(t.locale).numberingSystem==="latn"}var oI=class{constructor(e,r,n){this.padTo=n.padTo||0,this.floor=n.floor||!1;let{padTo:i,floor:o,...s}=n;if(!r||Object.keys(s).length>0){let a={useGrouping:!1,...n};n.padTo>0&&(a.minimumIntegerDigits=n.padTo),this.inf=MZ(e,a)}}format(e){if(this.inf){let r=this.floor?Math.floor(e):e;return this.inf.format(r)}else{let r=this.floor?Math.floor(e):gI(e,3);return gt(r,this.padTo)}}},sI=class{constructor(e,r,n){this.opts=n,this.originalZone=void 0;let i;if(this.opts.timeZone)this.dt=e;else if(e.zone.type==="fixed"){let s=-1*(e.offset/60),a=s>=0?`Etc/GMT+${s}`:`Etc/GMT${s}`;e.offset!==0&&Co.create(a).valid?(i=a,this.dt=e):(i="UTC",this.dt=e.offset===0?e:e.setZone("UTC").plus({minutes:e.offset}),this.originalZone=e.zone)}else e.zone.type==="system"?this.dt=e:e.zone.type==="iana"?(this.dt=e,i=e.zone.name):(i="UTC",this.dt=e.setZone("UTC").plus({minutes:e.offset}),this.originalZone=e.zone);let o={...this.opts};o.timeZone=o.timeZone||i,this.dtf=eI(r,o)}format(){return this.originalZone?this.formatToParts().map(({value:e})=>e).join(""):this.dtf.format(this.dt.toJSDate())}formatToParts(){let e=this.dtf.formatToParts(this.dt.toJSDate());return this.originalZone?e.map(r=>{if(r.type==="timeZoneName"){let n=this.originalZone.offsetName(this.dt.ts,{locale:this.dt.locale,format:this.opts.timeZoneName});return{...r,value:n}}else return r}):e}resolvedOptions(){return this.dtf.resolvedOptions()}},aI=class{constructor(e,r,n){this.opts={style:"long",...n},!r&&aT()&&(this.rtf=xZ(e,n))}format(e,r){return this.rtf?this.rtf.format(e,r):d6(r,e,this.opts.numeric,this.opts.style!=="long")}formatToParts(e,r){return this.rtf?this.rtf.formatToParts(e,r):[]}},eT={firstDay:1,minimalDays:4,weekend:[6,7]},Ge=class t{static fromOpts(e){return t.create(e.locale,e.numberingSystem,e.outputCalendar,e.weekSettings,e.defaultToEN)}static create(e,r,n,i,o=!1){let s=e||Je.defaultLocale,a=s||(o?"en-US":LZ()),c=r||Je.defaultNumberingSystem,u=n||Je.defaultOutputCalendar,l=uI(i)||Je.defaultWeekSettings;return new t(a,c,u,l,s)}static resetCache(){ml=null,XE.clear(),tI.clear(),rI.clear(),nI.clear(),iI.clear()}static fromObject({locale:e,numberingSystem:r,outputCalendar:n,weekSettings:i}={}){return t.create(e,r,n,i)}constructor(e,r,n,i,o){let[s,a,c]=FZ(e);this.locale=s,this.numberingSystem=r||a||null,this.outputCalendar=n||c||null,this.weekSettings=i,this.intl=$Z(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=o,this.fastNumbersCached=null}get fastNumbers(){return this.fastNumbersCached==null&&(this.fastNumbersCached=HZ(this)),this.fastNumbersCached}listingMode(){let e=this.isEnglish(),r=(this.numberingSystem===null||this.numberingSystem==="latn")&&(this.outputCalendar===null||this.outputCalendar==="gregory");return e&&r?"en":"intl"}clone(e){return!e||Object.getOwnPropertyNames(e).length===0?this:t.create(e.locale||this.specifiedLocale,e.numberingSystem||this.numberingSystem,e.outputCalendar||this.outputCalendar,uI(e.weekSettings)||this.weekSettings,e.defaultToEN||!1)}redefaultToEN(e={}){return this.clone({...e,defaultToEN:!0})}redefaultToSystem(e={}){return this.clone({...e,defaultToEN:!1})}months(e,r=!1){return gp(this,e,AT,()=>{let n=this.intl==="ja"||this.intl.startsWith("ja-");r&=!n;let i=r?{month:e,day:"numeric"}:{month:e},o=r?"format":"standalone";if(!this.monthsCache[o][e]){let s=n?a=>this.dtFormatter(a,i).format():a=>this.extract(a,i,"month");this.monthsCache[o][e]=jZ(s)}return this.monthsCache[o][e]})}weekdays(e,r=!1){return gp(this,e,hT,()=>{let n=r?{weekday:e,year:"numeric",month:"long",day:"numeric"}:{weekday:e},i=r?"format":"standalone";return this.weekdaysCache[i][e]||(this.weekdaysCache[i][e]=qZ(o=>this.extract(o,n,"weekday"))),this.weekdaysCache[i][e]})}meridiems(){return gp(this,void 0,()=>gT,()=>{if(!this.meridiemCache){let e={hour:"numeric",hourCycle:"h12"};this.meridiemCache=[Xe.utc(2016,11,13,9),Xe.utc(2016,11,13,19)].map(r=>this.extract(r,e,"dayperiod"))}return this.meridiemCache})}eras(e){return gp(this,e,mT,()=>{let r={era:e};return this.eraCache[e]||(this.eraCache[e]=[Xe.utc(-40,1,1),Xe.utc(2017,1,1)].map(n=>this.extract(n,r,"era"))),this.eraCache[e]})}extract(e,r,n){let i=this.dtFormatter(e,r),o=i.formatToParts(),s=o.find(a=>a.type.toLowerCase()===n);return s?s.value:null}numberFormatter(e={}){return new oI(this.intl,e.forceSimple||this.fastNumbers,e)}dtFormatter(e,r={}){return new sI(e,this.intl,r)}relFormatter(e={}){return new aI(this.intl,this.isEnglish(),e)}listFormatter(e={}){return UZ(this.intl,e)}isEnglish(){return this.locale==="en"||this.locale.toLowerCase()==="en-us"||XD(this.intl).locale.startsWith("en-us")}getWeekSettings(){return this.weekSettings?this.weekSettings:cT()?PZ(this.locale):eT}getStartOfWeek(){return this.getWeekSettings().firstDay}getMinDaysInFirstWeek(){return this.getWeekSettings().minimalDays}getWeekendDays(){return this.getWeekSettings().weekend}equals(e){return this.locale===e.locale&&this.numberingSystem===e.numberingSystem&&this.outputCalendar===e.outputCalendar}toString(){return`Locale(${this.locale}, ${this.numberingSystem}, ${this.outputCalendar})`}},jE=null,_r=class t extends as{static get utcInstance(){return jE===null&&(jE=new t(0)),jE}static instance(e){return e===0?t.utcInstance:new t(e)}static parseSpecifier(e){if(e){let r=e.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(r)return new t(Np(r[1],r[2]))}return null}constructor(e){super(),this.fixed=e}get type(){return"fixed"}get name(){return this.fixed===0?"UTC":`UTC${Il(this.fixed,"narrow")}`}get ianaName(){return this.fixed===0?"Etc/UTC":`Etc/GMT${Il(-this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(e,r){return Il(this.fixed,r)}get isUniversal(){return!0}offset(){return this.fixed}equals(e){return e.type==="fixed"&&e.fixed===this.fixed}get isValid(){return!0}},wp=class extends as{constructor(e){super(),this.zoneName=e}get type(){return"invalid"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(){return null}formatOffset(){return""}offset(){return NaN}equals(){return!1}get isValid(){return!1}};function is(t,e){if(pe(t)||t===null)return e;if(t instanceof as)return t;if(WZ(t)){let r=t.toLowerCase();return r==="default"?e:r==="local"||r==="system"?Cl.instance:r==="utc"||r==="gmt"?_r.utcInstance:_r.parseSpecifier(r)||Co.create(t)}else return ss(t)?_r.instance(t):typeof t=="object"&&"offset"in t&&typeof t.offset=="function"?t:new wp(t)}var AI={arab:"[\u0660-\u0669]",arabext:"[\u06F0-\u06F9]",bali:"[\u1B50-\u1B59]",beng:"[\u09E6-\u09EF]",deva:"[\u0966-\u096F]",fullwide:"[\uFF10-\uFF19]",gujr:"[\u0AE6-\u0AEF]",hanidec:"[\u3007|\u4E00|\u4E8C|\u4E09|\u56DB|\u4E94|\u516D|\u4E03|\u516B|\u4E5D]",khmr:"[\u17E0-\u17E9]",knda:"[\u0CE6-\u0CEF]",laoo:"[\u0ED0-\u0ED9]",limb:"[\u1946-\u194F]",mlym:"[\u0D66-\u0D6F]",mong:"[\u1810-\u1819]",mymr:"[\u1040-\u1049]",orya:"[\u0B66-\u0B6F]",tamldec:"[\u0BE6-\u0BEF]",telu:"[\u0C66-\u0C6F]",thai:"[\u0E50-\u0E59]",tibt:"[\u0F20-\u0F29]",latn:"\\d"},oD={arab:[1632,1641],arabext:[1776,1785],bali:[6992,7001],beng:[2534,2543],deva:[2406,2415],fullwide:[65296,65303],gujr:[2790,2799],khmr:[6112,6121],knda:[3302,3311],laoo:[3792,3801],limb:[6470,6479],mlym:[3430,3439],mong:[6160,6169],mymr:[4160,4169],orya:[2918,2927],tamldec:[3046,3055],telu:[3174,3183],thai:[3664,3673],tibt:[3872,3881]},zZ=AI.hanidec.replace(/[\[|\]]/g,"").split("");function GZ(t){let e=parseInt(t,10);if(isNaN(e)){e="";for(let r=0;r<t.length;r++){let n=t.charCodeAt(r);if(t[r].search(AI.hanidec)!==-1)e+=zZ.indexOf(t[r]);else for(let i in oD){let[o,s]=oD[i];n>=o&&n<=s&&(e+=n-o)}}return parseInt(e,10)}else return e}var cI=new Map;function YZ(){cI.clear()}function Bn({numberingSystem:t},e=""){let r=t||"latn",n=cI.get(r);n===void 0&&(n=new Map,cI.set(r,n));let i=n.get(e);return i===void 0&&(i=new RegExp(`${AI[r]}${e}`),n.set(e,i)),i}var sD=()=>Date.now(),aD="system",cD=null,uD=null,lD=null,dD=60,AD,pD=null,Je=class{static get now(){return sD}static set now(e){sD=e}static set defaultZone(e){aD=e}static get defaultZone(){return is(aD,Cl.instance)}static get defaultLocale(){return cD}static set defaultLocale(e){cD=e}static get defaultNumberingSystem(){return uD}static set defaultNumberingSystem(e){uD=e}static get defaultOutputCalendar(){return lD}static set defaultOutputCalendar(e){lD=e}static get defaultWeekSettings(){return pD}static set defaultWeekSettings(e){pD=uI(e)}static get twoDigitCutoffYear(){return dD}static set twoDigitCutoffYear(e){dD=e%100}static get throwOnInvalid(){return AD}static set throwOnInvalid(e){AD=e}static resetCaches(){Ge.resetCache(),Co.resetCache(),Xe.resetCache(),YZ()}},Qr=class{constructor(e,r){this.reason=e,this.explanation=r}toMessage(){return this.explanation?`${this.reason}: ${this.explanation}`:this.reason}},tT=[0,31,59,90,120,151,181,212,243,273,304,334],rT=[0,31,60,91,121,152,182,213,244,274,305,335];function Wr(t,e){return new Qr("unit out of range",`you specified ${e} (of type ${typeof e}) as a ${t}, which is invalid`)}function pI(t,e,r){let n=new Date(Date.UTC(t,e-1,r));t<100&&t>=0&&n.setUTCFullYear(n.getUTCFullYear()-1900);let i=n.getUTCDay();return i===0?7:i}function nT(t,e,r){return r+(Sl(t)?rT:tT)[e-1]}function iT(t,e){let r=Sl(t)?rT:tT,n=r.findIndex(o=>o<e),i=e-r[n];return{month:n+1,day:i}}function fI(t,e){return(t-e+7)%7+1}function Qp(t,e=4,r=1){let{year:n,month:i,day:o}=t,s=nT(n,i,o),a=fI(pI(n,i,o),r),c=Math.floor((s-a+14-e)/7),u;return c<1?(u=n-1,c=bl(u,e,r)):c>bl(n,e,r)?(u=n+1,c=1):u=n,{weekYear:u,weekNumber:c,weekday:a,...kp(t)}}function fD(t,e=4,r=1){let{weekYear:n,weekNumber:i,weekday:o}=t,s=fI(pI(n,1,e),r),a=bc(n),c=i*7+o-s-7+e,u;c<1?(u=n-1,c+=bc(u)):c>a?(u=n+1,c-=bc(n)):u=n;let{month:l,day:d}=iT(u,c);return{year:u,month:l,day:d,...kp(t)}}function qE(t){let{year:e,month:r,day:n}=t,i=nT(e,r,n);return{year:e,ordinal:i,...kp(t)}}function hD(t){let{year:e,ordinal:r}=t,{month:n,day:i}=iT(e,r);return{year:e,month:n,day:i,...kp(t)}}function gD(t,e){if(!pe(t.localWeekday)||!pe(t.localWeekNumber)||!pe(t.localWeekYear)){if(!pe(t.weekday)||!pe(t.weekNumber)||!pe(t.weekYear))throw new os("Cannot mix locale-based week fields with ISO-based week fields");return pe(t.localWeekday)||(t.weekday=t.localWeekday),pe(t.localWeekNumber)||(t.weekNumber=t.localWeekNumber),pe(t.localWeekYear)||(t.weekYear=t.localWeekYear),delete t.localWeekday,delete t.localWeekNumber,delete t.localWeekYear,{minDaysInFirstWeek:e.getMinDaysInFirstWeek(),startOfWeek:e.getStartOfWeek()}}else return{minDaysInFirstWeek:4,startOfWeek:1}}function VZ(t,e=4,r=1){let n=Tp(t.weekYear),i=Zr(t.weekNumber,1,bl(t.weekYear,e,r)),o=Zr(t.weekday,1,7);return n?i?o?!1:Wr("weekday",t.weekday):Wr("week",t.weekNumber):Wr("weekYear",t.weekYear)}function JZ(t){let e=Tp(t.year),r=Zr(t.ordinal,1,bc(t.year));return e?r?!1:Wr("ordinal",t.ordinal):Wr("year",t.year)}function oT(t){let e=Tp(t.year),r=Zr(t.month,1,12),n=Zr(t.day,1,vp(t.year,t.month));return e?r?n?!1:Wr("day",t.day):Wr("month",t.month):Wr("year",t.year)}function sT(t){let{hour:e,minute:r,second:n,millisecond:i}=t,o=Zr(e,0,23)||e===24&&r===0&&n===0&&i===0,s=Zr(r,0,59),a=Zr(n,0,59),c=Zr(i,0,999);return o?s?a?c?!1:Wr("millisecond",i):Wr("second",n):Wr("minute",r):Wr("hour",e)}function pe(t){return typeof t>"u"}function ss(t){return typeof t=="number"}function Tp(t){return typeof t=="number"&&t%1===0}function WZ(t){return typeof t=="string"}function ZZ(t){return Object.prototype.toString.call(t)==="[object Date]"}function aT(){try{return typeof Intl<"u"&&!!Intl.RelativeTimeFormat}catch{return!1}}function cT(){try{return typeof Intl<"u"&&!!Intl.Locale&&("weekInfo"in Intl.Locale.prototype||"getWeekInfo"in Intl.Locale.prototype)}catch{return!1}}function KZ(t){return Array.isArray(t)?t:[t]}function mD(t,e,r){if(t.length!==0)return t.reduce((n,i)=>{let o=[e(i),i];return n&&r(n[0],o[0])===n[0]?n:o},null)[1]}function XZ(t,e){return e.reduce((r,n)=>(r[n]=t[n],r),{})}function Bc(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function uI(t){if(t==null)return null;if(typeof t!="object")throw new _t("Week settings must be an object");if(!Zr(t.firstDay,1,7)||!Zr(t.minimalDays,1,7)||!Array.isArray(t.weekend)||t.weekend.some(e=>!Zr(e,1,7)))throw new _t("Invalid week settings");return{firstDay:t.firstDay,minimalDays:t.minimalDays,weekend:Array.from(t.weekend)}}function Zr(t,e,r){return Tp(t)&&t>=e&&t<=r}function e6(t,e){return t-e*Math.floor(t/e)}function gt(t,e=2){let r=t<0,n;return r?n="-"+(""+-t).padStart(e,"0"):n=(""+t).padStart(e,"0"),n}function ns(t){if(!(pe(t)||t===null||t===""))return parseInt(t,10)}function oa(t){if(!(pe(t)||t===null||t===""))return parseFloat(t)}function hI(t){if(!(pe(t)||t===null||t==="")){let e=parseFloat("0."+t)*1e3;return Math.floor(e)}}function gI(t,e,r="round"){let n=10**e;switch(r){case"expand":return t>0?Math.ceil(t*n)/n:Math.floor(t*n)/n;case"trunc":return Math.trunc(t*n)/n;case"round":return Math.round(t*n)/n;case"floor":return Math.floor(t*n)/n;case"ceil":return Math.ceil(t*n)/n;default:throw new RangeError(`Value rounding ${r} is out of range`)}}function Sl(t){return t%4===0&&(t%100!==0||t%400===0)}function bc(t){return Sl(t)?366:365}function vp(t,e){let r=e6(e-1,12)+1,n=t+(e-r)/12;return r===2?Sl(n)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][r-1]}function Rp(t){let e=Date.UTC(t.year,t.month-1,t.day,t.hour,t.minute,t.second,t.millisecond);return t.year<100&&t.year>=0&&(e=new Date(e),e.setUTCFullYear(t.year,t.month-1,t.day)),+e}function yD(t,e,r){return-fI(pI(t,1,e),r)+e-1}function bl(t,e=4,r=1){let n=yD(t,e,r),i=yD(t+1,e,r);return(bc(t)-n+i)/7}function lI(t){return t>99?t:t>Je.twoDigitCutoffYear?1900+t:2e3+t}function uT(t,e,r,n=null){let i=new Date(t),o={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};n&&(o.timeZone=n);let s={timeZoneName:e,...o},a=new Intl.DateTimeFormat(r,s).formatToParts(i).find(c=>c.type.toLowerCase()==="timezonename");return a?a.value:null}function Np(t,e){let r=parseInt(t,10);Number.isNaN(r)&&(r=0);let n=parseInt(e,10)||0,i=r<0||Object.is(r,-0)?-n:n;return r*60+i}function lT(t){let e=Number(t);if(typeof t=="boolean"||t===""||!Number.isFinite(e))throw new _t(`Invalid unit value ${t}`);return e}function _p(t,e){let r={};for(let n in t)if(Bc(t,n)){let i=t[n];if(i==null)continue;r[e(n)]=lT(i)}return r}function Il(t,e){let r=Math.trunc(Math.abs(t/60)),n=Math.trunc(Math.abs(t%60)),i=t>=0?"+":"-";switch(e){case"short":return`${i}${gt(r,2)}:${gt(n,2)}`;case"narrow":return`${i}${r}${n>0?`:${n}`:""}`;case"techie":return`${i}${gt(r,2)}${gt(n,2)}`;default:throw new RangeError(`Value format ${e} is out of range for property format`)}}function kp(t){return XZ(t,["hour","minute","second","millisecond"])}var t6=["January","February","March","April","May","June","July","August","September","October","November","December"],dT=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],r6=["J","F","M","A","M","J","J","A","S","O","N","D"];function AT(t){switch(t){case"narrow":return[...r6];case"short":return[...dT];case"long":return[...t6];case"numeric":return["1","2","3","4","5","6","7","8","9","10","11","12"];case"2-digit":return["01","02","03","04","05","06","07","08","09","10","11","12"];default:return null}}var pT=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],fT=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],n6=["M","T","W","T","F","S","S"];function hT(t){switch(t){case"narrow":return[...n6];case"short":return[...fT];case"long":return[...pT];case"numeric":return["1","2","3","4","5","6","7"];default:return null}}var gT=["AM","PM"],i6=["Before Christ","Anno Domini"],o6=["BC","AD"],s6=["B","A"];function mT(t){switch(t){case"narrow":return[...s6];case"short":return[...o6];case"long":return[...i6];default:return null}}function a6(t){return gT[t.hour<12?0:1]}function c6(t,e){return hT(e)[t.weekday-1]}function u6(t,e){return AT(e)[t.month-1]}function l6(t,e){return mT(e)[t.year<0?0:1]}function d6(t,e,r="always",n=!1){let i={years:["year","yr."],quarters:["quarter","qtr."],months:["month","mo."],weeks:["week","wk."],days:["day","day","days"],hours:["hour","hr."],minutes:["minute","min."],seconds:["second","sec."]},o=["hours","minutes","seconds"].indexOf(t)===-1;if(r==="auto"&&o){let d=t==="days";switch(e){case 1:return d?"tomorrow":`next ${i[t][0]}`;case-1:return d?"yesterday":`last ${i[t][0]}`;case 0:return d?"today":`this ${i[t][0]}`}}let s=Object.is(e,-0)||e<0,a=Math.abs(e),c=a===1,u=i[t],l=n?c?u[1]:u[2]||u[1]:c?i[t][0]:t;return s?`${a} ${l} ago`:`in ${a} ${l}`}function ED(t,e){let r="";for(let n of t)n.literal?r+=n.val:r+=e(n.val);return r}var A6={D:Bp,DD:OD,DDD:UD,DDDD:MD,t:xD,tt:LD,ttt:PD,tttt:FD,T:$D,TT:jD,TTT:qD,TTTT:HD,f:zD,ff:YD,fff:JD,ffff:ZD,F:GD,FF:VD,FFF:WD,FFFF:KD},wr=class t{static create(e,r={}){return new t(e,r)}static parseFormat(e){let r=null,n="",i=!1,o=[];for(let s=0;s<e.length;s++){let a=e.charAt(s);a==="'"?((n.length>0||i)&&o.push({literal:i||/^\s+$/.test(n),val:n===""?"'":n}),r=null,n="",i=!i):i||a===r?n+=a:(n.length>0&&o.push({literal:/^\s+$/.test(n),val:n}),n=a,r=a)}return n.length>0&&o.push({literal:i||/^\s+$/.test(n),val:n}),o}static macroTokenToFormatOpts(e){return A6[e]}constructor(e,r){this.opts=r,this.loc=e,this.systemLoc=null}formatWithSystemDefault(e,r){return this.systemLoc===null&&(this.systemLoc=this.loc.redefaultToSystem()),this.systemLoc.dtFormatter(e,{...this.opts,...r}).format()}dtFormatter(e,r={}){return this.loc.dtFormatter(e,{...this.opts,...r})}formatDateTime(e,r){return this.dtFormatter(e,r).format()}formatDateTimeParts(e,r){return this.dtFormatter(e,r).formatToParts()}formatInterval(e,r){return this.dtFormatter(e.start,r).dtf.formatRange(e.start.toJSDate(),e.end.toJSDate())}resolvedOptions(e,r){return this.dtFormatter(e,r).resolvedOptions()}num(e,r=0,n=void 0){if(this.opts.forceSimple)return gt(e,r);let i={...this.opts};return r>0&&(i.padTo=r),n&&(i.signDisplay=n),this.loc.numberFormatter(i).format(e)}formatDateTimeFromString(e,r){let n=this.loc.listingMode()==="en",i=this.loc.outputCalendar&&this.loc.outputCalendar!=="gregory",o=(p,h)=>this.loc.extract(e,p,h),s=p=>e.isOffsetFixed&&e.offset===0&&p.allowZ?"Z":e.isValid?e.zone.formatOffset(e.ts,p.format):"",a=()=>n?a6(e):o({hour:"numeric",hourCycle:"h12"},"dayperiod"),c=(p,h)=>n?u6(e,p):o(h?{month:p}:{month:p,day:"numeric"},"month"),u=(p,h)=>n?c6(e,p):o(h?{weekday:p}:{weekday:p,month:"long",day:"numeric"},"weekday"),l=p=>{let h=t.macroTokenToFormatOpts(p);return h?this.formatWithSystemDefault(e,h):p},d=p=>n?l6(e,p):o({era:p},"era"),A=p=>{switch(p){case"S":return this.num(e.millisecond);case"u":case"SSS":return this.num(e.millisecond,3);case"s":return this.num(e.second);case"ss":return this.num(e.second,2);case"uu":return this.num(Math.floor(e.millisecond/10),2);case"uuu":return this.num(Math.floor(e.millisecond/100));case"m":return this.num(e.minute);case"mm":return this.num(e.minute,2);case"h":return this.num(e.hour%12===0?12:e.hour%12);case"hh":return this.num(e.hour%12===0?12:e.hour%12,2);case"H":return this.num(e.hour);case"HH":return this.num(e.hour,2);case"Z":return s({format:"narrow",allowZ:this.opts.allowZ});case"ZZ":return s({format:"short",allowZ:this.opts.allowZ});case"ZZZ":return s({format:"techie",allowZ:this.opts.allowZ});case"ZZZZ":return e.zone.offsetName(e.ts,{format:"short",locale:this.loc.locale});case"ZZZZZ":return e.zone.offsetName(e.ts,{format:"long",locale:this.loc.locale});case"z":return e.zoneName;case"a":return a();case"d":return i?o({day:"numeric"},"day"):this.num(e.day);case"dd":return i?o({day:"2-digit"},"day"):this.num(e.day,2);case"c":return this.num(e.weekday);case"ccc":return u("short",!0);case"cccc":return u("long",!0);case"ccccc":return u("narrow",!0);case"E":return this.num(e.weekday);case"EEE":return u("short",!1);case"EEEE":return u("long",!1);case"EEEEE":return u("narrow",!1);case"L":return i?o({month:"numeric",day:"numeric"},"month"):this.num(e.month);case"LL":return i?o({month:"2-digit",day:"numeric"},"month"):this.num(e.month,2);case"LLL":return c("short",!0);case"LLLL":return c("long",!0);case"LLLLL":return c("narrow",!0);case"M":return i?o({month:"numeric"},"month"):this.num(e.month);case"MM":return i?o({month:"2-digit"},"month"):this.num(e.month,2);case"MMM":return c("short",!1);case"MMMM":return c("long",!1);case"MMMMM":return c("narrow",!1);case"y":return i?o({year:"numeric"},"year"):this.num(e.year);case"yy":return i?o({year:"2-digit"},"year"):this.num(e.year.toString().slice(-2),2);case"yyyy":return i?o({year:"numeric"},"year"):this.num(e.year,4);case"yyyyyy":return i?o({year:"numeric"},"year"):this.num(e.year,6);case"G":return d("short");case"GG":return d("long");case"GGGGG":return d("narrow");case"kk":return this.num(e.weekYear.toString().slice(-2),2);case"kkkk":return this.num(e.weekYear,4);case"W":return this.num(e.weekNumber);case"WW":return this.num(e.weekNumber,2);case"n":return this.num(e.localWeekNumber);case"nn":return this.num(e.localWeekNumber,2);case"ii":return this.num(e.localWeekYear.toString().slice(-2),2);case"iiii":return this.num(e.localWeekYear,4);case"o":return this.num(e.ordinal);case"ooo":return this.num(e.ordinal,3);case"q":return this.num(e.quarter);case"qq":return this.num(e.quarter,2);case"X":return this.num(Math.floor(e.ts/1e3));case"x":return this.num(e.ts);default:return l(p)}};return ED(t.parseFormat(r),A)}formatDurationFromString(e,r){let n=this.opts.signMode==="negativeLargestOnly"?-1:1,i=l=>{switch(l[0]){case"S":return"milliseconds";case"s":return"seconds";case"m":return"minutes";case"h":return"hours";case"d":return"days";case"w":return"weeks";case"M":return"months";case"y":return"years";default:return null}},o=(l,d)=>A=>{let p=i(A);if(p){let h=d.isNegativeDuration&&p!==d.largestUnit?n:1,I;return this.opts.signMode==="negativeLargestOnly"&&p!==d.largestUnit?I="never":this.opts.signMode==="all"?I="always":I="auto",this.num(l.get(p)*h,A.length,I)}else return A},s=t.parseFormat(r),a=s.reduce((l,{literal:d,val:A})=>d?l:l.concat(A),[]),c=e.shiftTo(...a.map(i).filter(l=>l)),u={isNegativeDuration:c<0,largestUnit:Object.keys(c.values)[0]};return ED(s,o(c,u))}},yT=/[A-Za-z_+-]{1,256}(?::?\/[A-Za-z0-9_+-]{1,256}(?:\/[A-Za-z0-9_+-]{1,256})?)?/;function wc(...t){let e=t.reduce((r,n)=>r+n.source,"");return RegExp(`^${e}$`)}function Qc(...t){return e=>t.reduce(([r,n,i],o)=>{let[s,a,c]=o(e,i);return[{...r,...s},a||n,c]},[{},null,1]).slice(0,2)}function vc(t,...e){if(t==null)return[null,null];for(let[r,n]of e){let i=r.exec(t);if(i)return n(i)}return[null,null]}function ET(...t){return(e,r)=>{let n={},i;for(i=0;i<t.length;i++)n[t[i]]=ns(e[r+i]);return[n,null,r+i]}}var IT=/(?:([Zz])|([+-]\d\d)(?::?(\d\d))?)/,p6=`(?:${IT.source}?(?:\\[(${yT.source})\\])?)?`,mI=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,CT=RegExp(`${mI.source}${p6}`),yI=RegExp(`(?:[Tt]${CT.source})?`),f6=/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,h6=/(\d{4})-?W(\d\d)(?:-?(\d))?/,g6=/(\d{4})-?(\d{3})/,m6=ET("weekYear","weekNumber","weekDay"),y6=ET("year","ordinal"),E6=/(\d{4})-(\d\d)-(\d\d)/,bT=RegExp(`${mI.source} ?(?:${IT.source}|(${yT.source}))?`),I6=RegExp(`(?: ${bT.source})?`);function Sc(t,e,r){let n=t[e];return pe(n)?r:ns(n)}function C6(t,e){return[{year:Sc(t,e),month:Sc(t,e+1,1),day:Sc(t,e+2,1)},null,e+3]}function _c(t,e){return[{hours:Sc(t,e,0),minutes:Sc(t,e+1,0),seconds:Sc(t,e+2,0),milliseconds:hI(t[e+3])},null,e+4]}function Bl(t,e){let r=!t[e]&&!t[e+1],n=Np(t[e+1],t[e+2]),i=r?null:_r.instance(n);return[{},i,e+3]}function wl(t,e){let r=t[e]?Co.create(t[e]):null;return[{},r,e+1]}var b6=RegExp(`^T?${mI.source}$`),S6=/^-?P(?:(?:(-?\d{1,20}(?:\.\d{1,20})?)Y)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20}(?:\.\d{1,20})?)W)?(?:(-?\d{1,20}(?:\.\d{1,20})?)D)?(?:T(?:(-?\d{1,20}(?:\.\d{1,20})?)H)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20})(?:[.,](-?\d{1,20}))?S)?)?)$/;function B6(t){let[e,r,n,i,o,s,a,c,u]=t,l=e[0]==="-",d=c&&c[0]==="-",A=(p,h=!1)=>p!==void 0&&(h||p&&l)?-p:p;return[{years:A(oa(r)),months:A(oa(n)),weeks:A(oa(i)),days:A(oa(o)),hours:A(oa(s)),minutes:A(oa(a)),seconds:A(oa(c),c==="-0"),milliseconds:A(hI(u),d)}]}var w6={GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function EI(t,e,r,n,i,o,s){let a={year:e.length===2?lI(ns(e)):ns(e),month:dT.indexOf(r)+1,day:ns(n),hour:ns(i),minute:ns(o)};return s&&(a.second=ns(s)),t&&(a.weekday=t.length>3?pT.indexOf(t)+1:fT.indexOf(t)+1),a}var Q6=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|(?:([+-]\d\d)(\d\d)))$/;function v6(t){let[,e,r,n,i,o,s,a,c,u,l,d]=t,A=EI(e,i,n,r,o,s,a),p;return c?p=w6[c]:u?p=0:p=Np(l,d),[A,new _r(p)]}function _6(t){return t.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}var D6=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT$/,T6=/^(Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d\d)-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d\d) (\d\d):(\d\d):(\d\d) GMT$/,R6=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( \d|\d\d) (\d\d):(\d\d):(\d\d) (\d{4})$/;function ID(t){let[,e,r,n,i,o,s,a]=t;return[EI(e,i,n,r,o,s,a),_r.utcInstance]}function N6(t){let[,e,r,n,i,o,s,a]=t;return[EI(e,a,r,n,i,o,s),_r.utcInstance]}var k6=wc(f6,yI),O6=wc(h6,yI),U6=wc(g6,yI),M6=wc(CT),ST=Qc(C6,_c,Bl,wl),x6=Qc(m6,_c,Bl,wl),L6=Qc(y6,_c,Bl,wl),P6=Qc(_c,Bl,wl);function F6(t){return vc(t,[k6,ST],[O6,x6],[U6,L6],[M6,P6])}function $6(t){return vc(_6(t),[Q6,v6])}function j6(t){return vc(t,[D6,ID],[T6,ID],[R6,N6])}function q6(t){return vc(t,[S6,B6])}var H6=Qc(_c);function z6(t){return vc(t,[b6,H6])}var G6=wc(E6,I6),Y6=wc(bT),V6=Qc(_c,Bl,wl);function J6(t){return vc(t,[G6,ST],[Y6,V6])}var CD="Invalid Duration",BT={weeks:{days:7,hours:168,minutes:10080,seconds:10080*60,milliseconds:10080*60*1e3},days:{hours:24,minutes:1440,seconds:1440*60,milliseconds:1440*60*1e3},hours:{minutes:60,seconds:3600,milliseconds:3600*1e3},minutes:{seconds:60,milliseconds:60*1e3},seconds:{milliseconds:1e3}},W6={years:{quarters:4,months:12,weeks:52,days:365,hours:365*24,minutes:365*24*60,seconds:365*24*60*60,milliseconds:365*24*60*60*1e3},quarters:{months:3,weeks:13,days:91,hours:2184,minutes:2184*60,seconds:2184*60*60,milliseconds:2184*60*60*1e3},months:{weeks:4,days:30,hours:720,minutes:720*60,seconds:720*60*60,milliseconds:720*60*60*1e3},...BT},Jr=146097/400,Ec=146097/4800,Z6={years:{quarters:4,months:12,weeks:Jr/7,days:Jr,hours:Jr*24,minutes:Jr*24*60,seconds:Jr*24*60*60,milliseconds:Jr*24*60*60*1e3},quarters:{months:3,weeks:Jr/28,days:Jr/4,hours:Jr*24/4,minutes:Jr*24*60/4,seconds:Jr*24*60*60/4,milliseconds:Jr*24*60*60*1e3/4},months:{weeks:Ec/7,days:Ec,hours:Ec*24,minutes:Ec*24*60,seconds:Ec*24*60*60,milliseconds:Ec*24*60*60*1e3},...BT},aa=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],K6=aa.slice(0).reverse();function Eo(t,e,r=!1){let n={values:r?e.values:{...t.values,...e.values||{}},loc:t.loc.clone(e.loc),conversionAccuracy:e.conversionAccuracy||t.conversionAccuracy,matrix:e.matrix||t.matrix};return new bt(n)}function wT(t,e){var r;let n=(r=e.milliseconds)!=null?r:0;for(let i of K6.slice(1))e[i]&&(n+=e[i]*t[i].milliseconds);return n}function bD(t,e){let r=wT(t,e)<0?-1:1;aa.reduceRight((n,i)=>{if(pe(e[i]))return n;if(n){let o=e[n]*r,s=t[i][n],a=Math.floor(o/s);e[i]+=a*r,e[n]-=a*s*r}return i},null),aa.reduce((n,i)=>{if(pe(e[i]))return n;if(n){let o=e[n]%1;e[n]-=o,e[i]+=o*t[n][i]}return i},null)}function SD(t){let e={};for(let[r,n]of Object.entries(t))n!==0&&(e[r]=n);return e}var bt=class t{constructor(e){let r=e.conversionAccuracy==="longterm"||!1,n=r?Z6:W6;e.matrix&&(n=e.matrix),this.values=e.values,this.loc=e.loc||Ge.create(),this.conversionAccuracy=r?"longterm":"casual",this.invalid=e.invalid||null,this.matrix=n,this.isLuxonDuration=!0}static fromMillis(e,r){return t.fromObject({milliseconds:e},r)}static fromObject(e,r={}){if(e==null||typeof e!="object")throw new _t(`Duration.fromObject: argument expected to be an object, got ${e===null?"null":typeof e}`);return new t({values:_p(e,t.normalizeUnit),loc:Ge.fromObject(r),conversionAccuracy:r.conversionAccuracy,matrix:r.matrix})}static fromDurationLike(e){if(ss(e))return t.fromMillis(e);if(t.isDuration(e))return e;if(typeof e=="object")return t.fromObject(e);throw new _t(`Unknown duration argument ${e} of type ${typeof e}`)}static fromISO(e,r){let[n]=q6(e);return n?t.fromObject(n,r):t.invalid("unparsable",`the input "${e}" can't be parsed as ISO 8601`)}static fromISOTime(e,r){let[n]=z6(e);return n?t.fromObject(n,r):t.invalid("unparsable",`the input "${e}" can't be parsed as ISO 8601`)}static invalid(e,r=null){if(!e)throw new _t("need to specify a reason the Duration is invalid");let n=e instanceof Qr?e:new Qr(e,r);if(Je.throwOnInvalid)throw new ZE(n);return new t({invalid:n})}static normalizeUnit(e){let r={year:"years",years:"years",quarter:"quarters",quarters:"quarters",month:"months",months:"months",week:"weeks",weeks:"weeks",day:"days",days:"days",hour:"hours",hours:"hours",minute:"minutes",minutes:"minutes",second:"seconds",seconds:"seconds",millisecond:"milliseconds",milliseconds:"milliseconds"}[e&&e.toLowerCase()];if(!r)throw new Sp(e);return r}static isDuration(e){return e&&e.isLuxonDuration||!1}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}toFormat(e,r={}){let n={...r,floor:r.round!==!1&&r.floor!==!1};return this.isValid?wr.create(this.loc,n).formatDurationFromString(this,e):CD}toHuman(e={}){if(!this.isValid)return CD;let r=e.showZeros!==!1,n=aa.map(i=>{let o=this.values[i];return pe(o)||o===0&&!r?null:this.loc.numberFormatter({style:"unit",unitDisplay:"long",...e,unit:i.slice(0,-1)}).format(o)}).filter(i=>i);return this.loc.listFormatter({type:"conjunction",style:e.listStyle||"narrow",...e}).format(n)}toObject(){return this.isValid?{...this.values}:{}}toISO(){if(!this.isValid)return null;let e="P";return this.years!==0&&(e+=this.years+"Y"),(this.months!==0||this.quarters!==0)&&(e+=this.months+this.quarters*3+"M"),this.weeks!==0&&(e+=this.weeks+"W"),this.days!==0&&(e+=this.days+"D"),(this.hours!==0||this.minutes!==0||this.seconds!==0||this.milliseconds!==0)&&(e+="T"),this.hours!==0&&(e+=this.hours+"H"),this.minutes!==0&&(e+=this.minutes+"M"),(this.seconds!==0||this.milliseconds!==0)&&(e+=gI(this.seconds+this.milliseconds/1e3,3)+"S"),e==="P"&&(e+="T0S"),e}toISOTime(e={}){if(!this.isValid)return null;let r=this.toMillis();return r<0||r>=864e5?null:(e={suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended",...e,includeOffset:!1},Xe.fromMillis(r,{zone:"UTC"}).toISOTime(e))}toJSON(){return this.toISO()}toString(){return this.toISO()}[Symbol.for("nodejs.util.inspect.custom")](){return this.isValid?`Duration { values: ${JSON.stringify(this.values)} }`:`Duration { Invalid, reason: ${this.invalidReason} }`}toMillis(){return this.isValid?wT(this.matrix,this.values):NaN}valueOf(){return this.toMillis()}plus(e){if(!this.isValid)return this;let r=t.fromDurationLike(e),n={};for(let i of aa)(Bc(r.values,i)||Bc(this.values,i))&&(n[i]=r.get(i)+this.get(i));return Eo(this,{values:n},!0)}minus(e){if(!this.isValid)return this;let r=t.fromDurationLike(e);return this.plus(r.negate())}mapUnits(e){if(!this.isValid)return this;let r={};for(let n of Object.keys(this.values))r[n]=lT(e(this.values[n],n));return Eo(this,{values:r},!0)}get(e){return this[t.normalizeUnit(e)]}set(e){if(!this.isValid)return this;let r={...this.values,..._p(e,t.normalizeUnit)};return Eo(this,{values:r})}reconfigure({locale:e,numberingSystem:r,conversionAccuracy:n,matrix:i}={}){let s={loc:this.loc.clone({locale:e,numberingSystem:r}),matrix:i,conversionAccuracy:n};return Eo(this,s)}as(e){return this.isValid?this.shiftTo(e).get(e):NaN}normalize(){if(!this.isValid)return this;let e=this.toObject();return bD(this.matrix,e),Eo(this,{values:e},!0)}rescale(){if(!this.isValid)return this;let e=SD(this.normalize().shiftToAll().toObject());return Eo(this,{values:e},!0)}shiftTo(...e){if(!this.isValid)return this;if(e.length===0)return this;e=e.map(s=>t.normalizeUnit(s));let r={},n={},i=this.toObject(),o;for(let s of aa)if(e.indexOf(s)>=0){o=s;let a=0;for(let u in n)a+=this.matrix[u][s]*n[u],n[u]=0;ss(i[s])&&(a+=i[s]);let c=Math.trunc(a);r[s]=c,n[s]=(a*1e3-c*1e3)/1e3}else ss(i[s])&&(n[s]=i[s]);for(let s in n)n[s]!==0&&(r[o]+=s===o?n[s]:n[s]/this.matrix[o][s]);return bD(this.matrix,r),Eo(this,{values:r},!0)}shiftToAll(){return this.isValid?this.shiftTo("years","months","weeks","days","hours","minutes","seconds","milliseconds"):this}negate(){if(!this.isValid)return this;let e={};for(let r of Object.keys(this.values))e[r]=this.values[r]===0?0:-this.values[r];return Eo(this,{values:e},!0)}removeZeros(){if(!this.isValid)return this;let e=SD(this.values);return Eo(this,{values:e},!0)}get years(){return this.isValid?this.values.years||0:NaN}get quarters(){return this.isValid?this.values.quarters||0:NaN}get months(){return this.isValid?this.values.months||0:NaN}get weeks(){return this.isValid?this.values.weeks||0:NaN}get days(){return this.isValid?this.values.days||0:NaN}get hours(){return this.isValid?this.values.hours||0:NaN}get minutes(){return this.isValid?this.values.minutes||0:NaN}get seconds(){return this.isValid?this.values.seconds||0:NaN}get milliseconds(){return this.isValid?this.values.milliseconds||0:NaN}get isValid(){return this.invalid===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}equals(e){if(!this.isValid||!e.isValid||!this.loc.equals(e.loc))return!1;function r(n,i){return n===void 0||n===0?i===void 0||i===0:n===i}for(let n of aa)if(!r(this.values[n],e.values[n]))return!1;return!0}},Ic="Invalid Interval";function X6(t,e){return!t||!t.isValid?ua.invalid("missing or invalid start"):!e||!e.isValid?ua.invalid("missing or invalid end"):e<t?ua.invalid("end before start",`The end of an interval must be after its start, but you had start=${t.toISO()} and end=${e.toISO()}`):null}var ua=class t{constructor(e){this.s=e.start,this.e=e.end,this.invalid=e.invalid||null,this.isLuxonInterval=!0}static invalid(e,r=null){if(!e)throw new _t("need to specify a reason the Interval is invalid");let n=e instanceof Qr?e:new Qr(e,r);if(Je.throwOnInvalid)throw new WE(n);return new t({invalid:n})}static fromDateTimes(e,r){let n=gl(e),i=gl(r),o=X6(n,i);return o??new t({start:n,end:i})}static after(e,r){let n=bt.fromDurationLike(r),i=gl(e);return t.fromDateTimes(i,i.plus(n))}static before(e,r){let n=bt.fromDurationLike(r),i=gl(e);return t.fromDateTimes(i.minus(n),i)}static fromISO(e,r){let[n,i]=(e||"").split("/",2);if(n&&i){let o,s;try{o=Xe.fromISO(n,r),s=o.isValid}catch{s=!1}let a,c;try{a=Xe.fromISO(i,r),c=a.isValid}catch{c=!1}if(s&&c)return t.fromDateTimes(o,a);if(s){let u=bt.fromISO(i,r);if(u.isValid)return t.after(o,u)}else if(c){let u=bt.fromISO(n,r);if(u.isValid)return t.before(a,u)}}return t.invalid("unparsable",`the input "${e}" can't be parsed as ISO 8601`)}static isInterval(e){return e&&e.isLuxonInterval||!1}get start(){return this.isValid?this.s:null}get end(){return this.isValid?this.e:null}get lastDateTime(){return this.isValid&&this.e?this.e.minus(1):null}get isValid(){return this.invalidReason===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}length(e="milliseconds"){return this.isValid?this.toDuration(e).get(e):NaN}count(e="milliseconds",r){if(!this.isValid)return NaN;let n=this.start.startOf(e,r),i;return r!=null&&r.useLocaleWeeks?i=this.end.reconfigure({locale:n.locale}):i=this.end,i=i.startOf(e,r),Math.floor(i.diff(n,e).get(e))+(i.valueOf()!==this.end.valueOf())}hasSame(e){return this.isValid?this.isEmpty()||this.e.minus(1).hasSame(this.s,e):!1}isEmpty(){return this.s.valueOf()===this.e.valueOf()}isAfter(e){return this.isValid?this.s>e:!1}isBefore(e){return this.isValid?this.e<=e:!1}contains(e){return this.isValid?this.s<=e&&this.e>e:!1}set({start:e,end:r}={}){return this.isValid?t.fromDateTimes(e||this.s,r||this.e):this}splitAt(...e){if(!this.isValid)return[];let r=e.map(gl).filter(s=>this.contains(s)).sort((s,a)=>s.toMillis()-a.toMillis()),n=[],{s:i}=this,o=0;for(;i<this.e;){let s=r[o]||this.e,a=+s>+this.e?this.e:s;n.push(t.fromDateTimes(i,a)),i=a,o+=1}return n}splitBy(e){let r=bt.fromDurationLike(e);if(!this.isValid||!r.isValid||r.as("milliseconds")===0)return[];let{s:n}=this,i=1,o,s=[];for(;n<this.e;){let a=this.start.plus(r.mapUnits(c=>c*i));o=+a>+this.e?this.e:a,s.push(t.fromDateTimes(n,o)),n=o,i+=1}return s}divideEqually(e){return this.isValid?this.splitBy(this.length()/e).slice(0,e):[]}overlaps(e){return this.e>e.s&&this.s<e.e}abutsStart(e){return this.isValid?+this.e==+e.s:!1}abutsEnd(e){return this.isValid?+e.e==+this.s:!1}engulfs(e){return this.isValid?this.s<=e.s&&this.e>=e.e:!1}equals(e){return!this.isValid||!e.isValid?!1:this.s.equals(e.s)&&this.e.equals(e.e)}intersection(e){if(!this.isValid)return this;let r=this.s>e.s?this.s:e.s,n=this.e<e.e?this.e:e.e;return r>=n?null:t.fromDateTimes(r,n)}union(e){if(!this.isValid)return this;let r=this.s<e.s?this.s:e.s,n=this.e>e.e?this.e:e.e;return t.fromDateTimes(r,n)}static merge(e){let[r,n]=e.sort((i,o)=>i.s-o.s).reduce(([i,o],s)=>o?o.overlaps(s)||o.abutsStart(s)?[i,o.union(s)]:[i.concat([o]),s]:[i,s],[[],null]);return n&&r.push(n),r}static xor(e){let r=null,n=0,i=[],o=e.map(c=>[{time:c.s,type:"s"},{time:c.e,type:"e"}]),s=Array.prototype.concat(...o),a=s.sort((c,u)=>c.time-u.time);for(let c of a)n+=c.type==="s"?1:-1,n===1?r=c.time:(r&&+r!=+c.time&&i.push(t.fromDateTimes(r,c.time)),r=null);return t.merge(i)}difference(...e){return t.xor([this].concat(e)).map(r=>this.intersection(r)).filter(r=>r&&!r.isEmpty())}toString(){return this.isValid?`[${this.s.toISO()} \u2013 ${this.e.toISO()})`:Ic}[Symbol.for("nodejs.util.inspect.custom")](){return this.isValid?`Interval { start: ${this.s.toISO()}, end: ${this.e.toISO()} }`:`Interval { Invalid, reason: ${this.invalidReason} }`}toLocaleString(e=Bp,r={}){return this.isValid?wr.create(this.s.loc.clone(r),e).formatInterval(this):Ic}toISO(e){return this.isValid?`${this.s.toISO(e)}/${this.e.toISO(e)}`:Ic}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:Ic}toISOTime(e){return this.isValid?`${this.s.toISOTime(e)}/${this.e.toISOTime(e)}`:Ic}toFormat(e,{separator:r=" \u2013 "}={}){return this.isValid?`${this.s.toFormat(e)}${r}${this.e.toFormat(e)}`:Ic}toDuration(e,r){return this.isValid?this.e.diff(this.s,e,r):bt.invalid(this.invalidReason)}mapEndpoints(e){return t.fromDateTimes(e(this.s),e(this.e))}},ca=class{static hasDST(e=Je.defaultZone){let r=Xe.now().setZone(e).set({month:12});return!e.isUniversal&&r.offset!==r.set({month:6}).offset}static isValidIANAZone(e){return Co.isValidZone(e)}static normalizeZone(e){return is(e,Je.defaultZone)}static getStartOfWeek({locale:e=null,locObj:r=null}={}){return(r||Ge.create(e)).getStartOfWeek()}static getMinimumDaysInFirstWeek({locale:e=null,locObj:r=null}={}){return(r||Ge.create(e)).getMinDaysInFirstWeek()}static getWeekendWeekdays({locale:e=null,locObj:r=null}={}){return(r||Ge.create(e)).getWeekendDays().slice()}static months(e="long",{locale:r=null,numberingSystem:n=null,locObj:i=null,outputCalendar:o="gregory"}={}){return(i||Ge.create(r,n,o)).months(e)}static monthsFormat(e="long",{locale:r=null,numberingSystem:n=null,locObj:i=null,outputCalendar:o="gregory"}={}){return(i||Ge.create(r,n,o)).months(e,!0)}static weekdays(e="long",{locale:r=null,numberingSystem:n=null,locObj:i=null}={}){return(i||Ge.create(r,n,null)).weekdays(e)}static weekdaysFormat(e="long",{locale:r=null,numberingSystem:n=null,locObj:i=null}={}){return(i||Ge.create(r,n,null)).weekdays(e,!0)}static meridiems({locale:e=null}={}){return Ge.create(e).meridiems()}static eras(e="short",{locale:r=null}={}){return Ge.create(r,null,"gregory").eras(e)}static features(){return{relative:aT(),localeWeek:cT()}}};function BD(t,e){let r=i=>i.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf(),n=r(e)-r(t);return Math.floor(bt.fromMillis(n).as("days"))}function eK(t,e,r){let n=[["years",(c,u)=>u.year-c.year],["quarters",(c,u)=>u.quarter-c.quarter+(u.year-c.year)*4],["months",(c,u)=>u.month-c.month+(u.year-c.year)*12],["weeks",(c,u)=>{let l=BD(c,u);return(l-l%7)/7}],["days",BD]],i={},o=t,s,a;for(let[c,u]of n)r.indexOf(c)>=0&&(s=c,i[c]=u(t,e),a=o.plus(i),a>e?(i[c]--,t=o.plus(i),t>e&&(a=t,i[c]--,t=o.plus(i))):t=a);return[t,i,a,s]}function tK(t,e,r,n){let[i,o,s,a]=eK(t,e,r),c=e-i,u=r.filter(d=>["hours","minutes","seconds","milliseconds"].indexOf(d)>=0);u.length===0&&(s<e&&(s=i.plus({[a]:1})),s!==i&&(o[a]=(o[a]||0)+c/(s-i)));let l=bt.fromObject(o,n);return u.length>0?bt.fromMillis(c,n).shiftTo(...u).plus(l):l}var rK="missing Intl.DateTimeFormat.formatToParts support";function Oe(t,e=r=>r){return{regex:t,deser:([r])=>e(GZ(r))}}var nK="\xA0",QT=`[ ${nK}]`,vT=new RegExp(QT,"g");function iK(t){return t.replace(/\./g,"\\.?").replace(vT,QT)}function wD(t){return t.replace(/\./g,"").replace(vT," ").toLowerCase()}function wn(t,e){return t===null?null:{regex:RegExp(t.map(iK).join("|")),deser:([r])=>t.findIndex(n=>wD(r)===wD(n))+e}}function QD(t,e){return{regex:t,deser:([,r,n])=>Np(r,n),groups:e}}function mp(t){return{regex:t,deser:([e])=>e}}function oK(t){return t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function sK(t,e){let r=Bn(e),n=Bn(e,"{2}"),i=Bn(e,"{3}"),o=Bn(e,"{4}"),s=Bn(e,"{6}"),a=Bn(e,"{1,2}"),c=Bn(e,"{1,3}"),u=Bn(e,"{1,6}"),l=Bn(e,"{1,9}"),d=Bn(e,"{2,4}"),A=Bn(e,"{4,6}"),p=b=>({regex:RegExp(oK(b.val)),deser:([S])=>S,literal:!0}),I=(b=>{if(t.literal)return p(b);switch(b.val){case"G":return wn(e.eras("short"),0);case"GG":return wn(e.eras("long"),0);case"y":return Oe(u);case"yy":return Oe(d,lI);case"yyyy":return Oe(o);case"yyyyy":return Oe(A);case"yyyyyy":return Oe(s);case"M":return Oe(a);case"MM":return Oe(n);case"MMM":return wn(e.months("short",!0),1);case"MMMM":return wn(e.months("long",!0),1);case"L":return Oe(a);case"LL":return Oe(n);case"LLL":return wn(e.months("short",!1),1);case"LLLL":return wn(e.months("long",!1),1);case"d":return Oe(a);case"dd":return Oe(n);case"o":return Oe(c);case"ooo":return Oe(i);case"HH":return Oe(n);case"H":return Oe(a);case"hh":return Oe(n);case"h":return Oe(a);case"mm":return Oe(n);case"m":return Oe(a);case"q":return Oe(a);case"qq":return Oe(n);case"s":return Oe(a);case"ss":return Oe(n);case"S":return Oe(c);case"SSS":return Oe(i);case"u":return mp(l);case"uu":return mp(a);case"uuu":return Oe(r);case"a":return wn(e.meridiems(),0);case"kkkk":return Oe(o);case"kk":return Oe(d,lI);case"W":return Oe(a);case"WW":return Oe(n);case"E":case"c":return Oe(r);case"EEE":return wn(e.weekdays("short",!1),1);case"EEEE":return wn(e.weekdays("long",!1),1);case"ccc":return wn(e.weekdays("short",!0),1);case"cccc":return wn(e.weekdays("long",!0),1);case"Z":case"ZZ":return QD(new RegExp(`([+-]${a.source})(?::(${n.source}))?`),2);case"ZZZ":return QD(new RegExp(`([+-]${a.source})(${n.source})?`),2);case"z":return mp(/[a-z_+-/]{1,256}?/i);case" ":return mp(/[^\S\n\r]/);default:return p(b)}})(t)||{invalidReason:rK};return I.token=t,I}var aK={year:{"2-digit":"yy",numeric:"yyyyy"},month:{numeric:"M","2-digit":"MM",short:"MMM",long:"MMMM"},day:{numeric:"d","2-digit":"dd"},weekday:{short:"EEE",long:"EEEE"},dayperiod:"a",dayPeriod:"a",hour12:{numeric:"h","2-digit":"hh"},hour24:{numeric:"H","2-digit":"HH"},minute:{numeric:"m","2-digit":"mm"},second:{numeric:"s","2-digit":"ss"},timeZoneName:{long:"ZZZZZ",short:"ZZZ"}};function cK(t,e,r){let{type:n,value:i}=t;if(n==="literal"){let c=/^\s+$/.test(i);return{literal:!c,val:c?" ":i}}let o=e[n],s=n;n==="hour"&&(e.hour12!=null?s=e.hour12?"hour12":"hour24":e.hourCycle!=null?e.hourCycle==="h11"||e.hourCycle==="h12"?s="hour12":s="hour24":s=r.hour12?"hour12":"hour24");let a=aK[s];if(typeof a=="object"&&(a=a[o]),a)return{literal:!1,val:a}}function uK(t){return[`^${t.map(r=>r.regex).reduce((r,n)=>`${r}(${n.source})`,"")}$`,t]}function lK(t,e,r){let n=t.match(e);if(n){let i={},o=1;for(let s in r)if(Bc(r,s)){let a=r[s],c=a.groups?a.groups+1:1;!a.literal&&a.token&&(i[a.token.val[0]]=a.deser(n.slice(o,o+c))),o+=c}return[n,i]}else return[n,{}]}function dK(t){let e=o=>{switch(o){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":case"H":return"hour";case"d":return"day";case"o":return"ordinal";case"L":case"M":return"month";case"y":return"year";case"E":case"c":return"weekday";case"W":return"weekNumber";case"k":return"weekYear";case"q":return"quarter";default:return null}},r=null,n;return pe(t.z)||(r=Co.create(t.z)),pe(t.Z)||(r||(r=new _r(t.Z)),n=t.Z),pe(t.q)||(t.M=(t.q-1)*3+1),pe(t.h)||(t.h<12&&t.a===1?t.h+=12:t.h===12&&t.a===0&&(t.h=0)),t.G===0&&t.y&&(t.y=-t.y),pe(t.u)||(t.S=hI(t.u)),[Object.keys(t).reduce((o,s)=>{let a=e(s);return a&&(o[a]=t[s]),o},{}),r,n]}var HE=null;function AK(){return HE||(HE=Xe.fromMillis(1555555555555)),HE}function pK(t,e){if(t.literal)return t;let r=wr.macroTokenToFormatOpts(t.val),n=TT(r,e);return n==null||n.includes(void 0)?t:n}function _T(t,e){return Array.prototype.concat(...t.map(r=>pK(r,e)))}var Dp=class{constructor(e,r){if(this.locale=e,this.format=r,this.tokens=_T(wr.parseFormat(r),e),this.units=this.tokens.map(n=>sK(n,e)),this.disqualifyingUnit=this.units.find(n=>n.invalidReason),!this.disqualifyingUnit){let[n,i]=uK(this.units);this.regex=RegExp(n,"i"),this.handlers=i}}explainFromTokens(e){if(this.isValid){let[r,n]=lK(e,this.regex,this.handlers),[i,o,s]=n?dK(n):[null,null,void 0];if(Bc(n,"a")&&Bc(n,"H"))throw new os("Can't include meridiem when specifying 24-hour format");return{input:e,tokens:this.tokens,regex:this.regex,rawMatches:r,matches:n,result:i,zone:o,specificOffset:s}}else return{input:e,tokens:this.tokens,invalidReason:this.invalidReason}}get isValid(){return!this.disqualifyingUnit}get invalidReason(){return this.disqualifyingUnit?this.disqualifyingUnit.invalidReason:null}};function DT(t,e,r){return new Dp(t,r).explainFromTokens(e)}function fK(t,e,r){let{result:n,zone:i,specificOffset:o,invalidReason:s}=DT(t,e,r);return[n,i,o,s]}function TT(t,e){if(!t)return null;let n=wr.create(e,t).dtFormatter(AK()),i=n.formatToParts(),o=n.resolvedOptions();return i.map(s=>cK(s,t,o))}var zE="Invalid DateTime",vD=864e13;function yl(t){return new Qr("unsupported zone",`the zone "${t.name}" is not supported`)}function GE(t){return t.weekData===null&&(t.weekData=Qp(t.c)),t.weekData}function YE(t){return t.localWeekData===null&&(t.localWeekData=Qp(t.c,t.loc.getMinDaysInFirstWeek(),t.loc.getStartOfWeek())),t.localWeekData}function sa(t,e){let r={ts:t.ts,zone:t.zone,c:t.c,o:t.o,loc:t.loc,invalid:t.invalid};return new Xe({...r,...e,old:r})}function RT(t,e,r){let n=t-e*60*1e3,i=r.offset(n);if(e===i)return[n,e];n-=(i-e)*60*1e3;let o=r.offset(n);return i===o?[n,i]:[t-Math.min(i,o)*60*1e3,Math.max(i,o)]}function yp(t,e){t+=e*60*1e3;let r=new Date(t);return{year:r.getUTCFullYear(),month:r.getUTCMonth()+1,day:r.getUTCDate(),hour:r.getUTCHours(),minute:r.getUTCMinutes(),second:r.getUTCSeconds(),millisecond:r.getUTCMilliseconds()}}function Ip(t,e,r){return RT(Rp(t),e,r)}function _D(t,e){let r=t.o,n=t.c.year+Math.trunc(e.years),i=t.c.month+Math.trunc(e.months)+Math.trunc(e.quarters)*3,o={...t.c,year:n,month:i,day:Math.min(t.c.day,vp(n,i))+Math.trunc(e.days)+Math.trunc(e.weeks)*7},s=bt.fromObject({years:e.years-Math.trunc(e.years),quarters:e.quarters-Math.trunc(e.quarters),months:e.months-Math.trunc(e.months),weeks:e.weeks-Math.trunc(e.weeks),days:e.days-Math.trunc(e.days),hours:e.hours,minutes:e.minutes,seconds:e.seconds,milliseconds:e.milliseconds}).as("milliseconds"),a=Rp(o),[c,u]=RT(a,r,t.zone);return s!==0&&(c+=s,u=t.zone.offset(c)),{ts:c,o:u}}function Cc(t,e,r,n,i,o){let{setZone:s,zone:a}=r;if(t&&Object.keys(t).length!==0||e){let c=e||a,u=Xe.fromObject(t,{...r,zone:c,specificOffset:o});return s?u:u.setZone(a)}else return Xe.invalid(new Qr("unparsable",`the input "${i}" can't be parsed as ${n}`))}function Ep(t,e,r=!0){return t.isValid?wr.create(Ge.create("en-US"),{allowZ:r,forceSimple:!0}).formatDateTimeFromString(t,e):null}function VE(t,e,r){let n=t.c.year>9999||t.c.year<0,i="";if(n&&t.c.year>=0&&(i+="+"),i+=gt(t.c.year,n?6:4),r==="year")return i;if(e){if(i+="-",i+=gt(t.c.month),r==="month")return i;i+="-"}else if(i+=gt(t.c.month),r==="month")return i;return i+=gt(t.c.day),i}function DD(t,e,r,n,i,o,s){let a=!r||t.c.millisecond!==0||t.c.second!==0,c="";switch(s){case"day":case"month":case"year":break;default:if(c+=gt(t.c.hour),s==="hour")break;if(e){if(c+=":",c+=gt(t.c.minute),s==="minute")break;a&&(c+=":",c+=gt(t.c.second))}else{if(c+=gt(t.c.minute),s==="minute")break;a&&(c+=gt(t.c.second))}if(s==="second")break;a&&(!n||t.c.millisecond!==0)&&(c+=".",c+=gt(t.c.millisecond,3))}return i&&(t.isOffsetFixed&&t.offset===0&&!o?c+="Z":t.o<0?(c+="-",c+=gt(Math.trunc(-t.o/60)),c+=":",c+=gt(Math.trunc(-t.o%60))):(c+="+",c+=gt(Math.trunc(t.o/60)),c+=":",c+=gt(Math.trunc(t.o%60)))),o&&(c+="["+t.zone.ianaName+"]"),c}var NT={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},hK={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},gK={ordinal:1,hour:0,minute:0,second:0,millisecond:0},Cp=["year","month","day","hour","minute","second","millisecond"],mK=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],yK=["year","ordinal","hour","minute","second","millisecond"];function bp(t){let e={year:"year",years:"year",month:"month",months:"month",day:"day",days:"day",hour:"hour",hours:"hour",minute:"minute",minutes:"minute",quarter:"quarter",quarters:"quarter",second:"second",seconds:"second",millisecond:"millisecond",milliseconds:"millisecond",weekday:"weekday",weekdays:"weekday",weeknumber:"weekNumber",weeksnumber:"weekNumber",weeknumbers:"weekNumber",weekyear:"weekYear",weekyears:"weekYear",ordinal:"ordinal"}[t.toLowerCase()];if(!e)throw new Sp(t);return e}function TD(t){switch(t.toLowerCase()){case"localweekday":case"localweekdays":return"localWeekday";case"localweeknumber":case"localweeknumbers":return"localWeekNumber";case"localweekyear":case"localweekyears":return"localWeekYear";default:return bp(t)}}function EK(t){if(El===void 0&&(El=Je.now()),t.type!=="iana")return t.offset(El);let e=t.name,r=dI.get(e);return r===void 0&&(r=t.offset(El),dI.set(e,r)),r}function RD(t,e){let r=is(e.zone,Je.defaultZone);if(!r.isValid)return Xe.invalid(yl(r));let n=Ge.fromObject(e),i,o;if(pe(t.year))i=Je.now();else{for(let c of Cp)pe(t[c])&&(t[c]=NT[c]);let s=oT(t)||sT(t);if(s)return Xe.invalid(s);let a=EK(r);[i,o]=Ip(t,a,r)}return new Xe({ts:i,zone:r,loc:n,o})}function ND(t,e,r){let n=pe(r.round)?!0:r.round,i=pe(r.rounding)?"trunc":r.rounding,o=(a,c)=>(a=gI(a,n||r.calendary?0:2,r.calendary?"round":i),e.loc.clone(r).relFormatter(r).format(a,c)),s=a=>r.calendary?e.hasSame(t,a)?0:e.startOf(a).diff(t.startOf(a),a).get(a):e.diff(t,a).get(a);if(r.unit)return o(s(r.unit),r.unit);for(let a of r.units){let c=s(a);if(Math.abs(c)>=1)return o(c,a)}return o(t>e?-0:0,r.units[r.units.length-1])}function kD(t){let e={},r;return t.length>0&&typeof t[t.length-1]=="object"?(e=t[t.length-1],r=Array.from(t).slice(0,t.length-1)):r=Array.from(t),[e,r]}var El,dI=new Map,Xe=class t{constructor(e){let r=e.zone||Je.defaultZone,n=e.invalid||(Number.isNaN(e.ts)?new Qr("invalid input"):null)||(r.isValid?null:yl(r));this.ts=pe(e.ts)?Je.now():e.ts;let i=null,o=null;if(!n)if(e.old&&e.old.ts===this.ts&&e.old.zone.equals(r))[i,o]=[e.old.c,e.old.o];else{let a=ss(e.o)&&!e.old?e.o:r.offset(this.ts);i=yp(this.ts,a),n=Number.isNaN(i.year)?new Qr("invalid input"):null,i=n?null:i,o=n?null:a}this._zone=r,this.loc=e.loc||Ge.create(),this.invalid=n,this.weekData=null,this.localWeekData=null,this.c=i,this.o=o,this.isLuxonDateTime=!0}static now(){return new t({})}static local(){let[e,r]=kD(arguments),[n,i,o,s,a,c,u]=r;return RD({year:n,month:i,day:o,hour:s,minute:a,second:c,millisecond:u},e)}static utc(){let[e,r]=kD(arguments),[n,i,o,s,a,c,u]=r;return e.zone=_r.utcInstance,RD({year:n,month:i,day:o,hour:s,minute:a,second:c,millisecond:u},e)}static fromJSDate(e,r={}){let n=ZZ(e)?e.valueOf():NaN;if(Number.isNaN(n))return t.invalid("invalid input");let i=is(r.zone,Je.defaultZone);return i.isValid?new t({ts:n,zone:i,loc:Ge.fromObject(r)}):t.invalid(yl(i))}static fromMillis(e,r={}){if(ss(e))return e<-vD||e>vD?t.invalid("Timestamp out of range"):new t({ts:e,zone:is(r.zone,Je.defaultZone),loc:Ge.fromObject(r)});throw new _t(`fromMillis requires a numerical input, but received a ${typeof e} with value ${e}`)}static fromSeconds(e,r={}){if(ss(e))return new t({ts:e*1e3,zone:is(r.zone,Je.defaultZone),loc:Ge.fromObject(r)});throw new _t("fromSeconds requires a numerical input")}static fromObject(e,r={}){e=e||{};let n=is(r.zone,Je.defaultZone);if(!n.isValid)return t.invalid(yl(n));let i=Ge.fromObject(r),o=_p(e,TD),{minDaysInFirstWeek:s,startOfWeek:a}=gD(o,i),c=Je.now(),u=pe(r.specificOffset)?n.offset(c):r.specificOffset,l=!pe(o.ordinal),d=!pe(o.year),A=!pe(o.month)||!pe(o.day),p=d||A,h=o.weekYear||o.weekNumber;if((p||l)&&h)throw new os("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(A&&l)throw new os("Can't mix ordinal dates with month/day");let I=h||o.weekday&&!p,b,S,v=yp(c,u);I?(b=mK,S=hK,v=Qp(v,s,a)):l?(b=yK,S=gK,v=qE(v)):(b=Cp,S=NT);let w=!1;for(let Se of b){let Be=o[Se];pe(Be)?w?o[Se]=S[Se]:o[Se]=v[Se]:w=!0}let O=I?VZ(o,s,a):l?JZ(o):oT(o),U=O||sT(o);if(U)return t.invalid(U);let G=I?fD(o,s,a):l?hD(o):o,[W,te]=Ip(G,u,n),J=new t({ts:W,zone:n,o:te,loc:i});return o.weekday&&p&&e.weekday!==J.weekday?t.invalid("mismatched weekday",`you can't specify both a weekday of ${o.weekday} and a date of ${J.toISO()}`):J.isValid?J:t.invalid(J.invalid)}static fromISO(e,r={}){let[n,i]=F6(e);return Cc(n,i,r,"ISO 8601",e)}static fromRFC2822(e,r={}){let[n,i]=$6(e);return Cc(n,i,r,"RFC 2822",e)}static fromHTTP(e,r={}){let[n,i]=j6(e);return Cc(n,i,r,"HTTP",r)}static fromFormat(e,r,n={}){if(pe(e)||pe(r))throw new _t("fromFormat requires an input string and a format");let{locale:i=null,numberingSystem:o=null}=n,s=Ge.fromOpts({locale:i,numberingSystem:o,defaultToEN:!0}),[a,c,u,l]=fK(s,e,r);return l?t.invalid(l):Cc(a,c,n,`format ${r}`,e,u)}static fromString(e,r,n={}){return t.fromFormat(e,r,n)}static fromSQL(e,r={}){let[n,i]=J6(e);return Cc(n,i,r,"SQL",e)}static invalid(e,r=null){if(!e)throw new _t("need to specify a reason the DateTime is invalid");let n=e instanceof Qr?e:new Qr(e,r);if(Je.throwOnInvalid)throw new JE(n);return new t({invalid:n})}static isDateTime(e){return e&&e.isLuxonDateTime||!1}static parseFormatForOpts(e,r={}){let n=TT(e,Ge.fromObject(r));return n?n.map(i=>i?i.val:null).join(""):null}static expandFormat(e,r={}){return _T(wr.parseFormat(e),Ge.fromObject(r)).map(i=>i.val).join("")}static resetCache(){El=void 0,dI.clear()}get(e){return this[e]}get isValid(){return this.invalid===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}get outputCalendar(){return this.isValid?this.loc.outputCalendar:null}get zone(){return this._zone}get zoneName(){return this.isValid?this.zone.name:null}get year(){return this.isValid?this.c.year:NaN}get quarter(){return this.isValid?Math.ceil(this.c.month/3):NaN}get month(){return this.isValid?this.c.month:NaN}get day(){return this.isValid?this.c.day:NaN}get hour(){return this.isValid?this.c.hour:NaN}get minute(){return this.isValid?this.c.minute:NaN}get second(){return this.isValid?this.c.second:NaN}get millisecond(){return this.isValid?this.c.millisecond:NaN}get weekYear(){return this.isValid?GE(this).weekYear:NaN}get weekNumber(){return this.isValid?GE(this).weekNumber:NaN}get weekday(){return this.isValid?GE(this).weekday:NaN}get isWeekend(){return this.isValid&&this.loc.getWeekendDays().includes(this.weekday)}get localWeekday(){return this.isValid?YE(this).weekday:NaN}get localWeekNumber(){return this.isValid?YE(this).weekNumber:NaN}get localWeekYear(){return this.isValid?YE(this).weekYear:NaN}get ordinal(){return this.isValid?qE(this.c).ordinal:NaN}get monthShort(){return this.isValid?ca.months("short",{locObj:this.loc})[this.month-1]:null}get monthLong(){return this.isValid?ca.months("long",{locObj:this.loc})[this.month-1]:null}get weekdayShort(){return this.isValid?ca.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}get weekdayLong(){return this.isValid?ca.weekdays("long",{locObj:this.loc})[this.weekday-1]:null}get offset(){return this.isValid?+this.o:NaN}get offsetNameShort(){return this.isValid?this.zone.offsetName(this.ts,{format:"short",locale:this.locale}):null}get offsetNameLong(){return this.isValid?this.zone.offsetName(this.ts,{format:"long",locale:this.locale}):null}get isOffsetFixed(){return this.isValid?this.zone.isUniversal:null}get isInDST(){return this.isOffsetFixed?!1:this.offset>this.set({month:1,day:1}).offset||this.offset>this.set({month:5}).offset}getPossibleOffsets(){if(!this.isValid||this.isOffsetFixed)return[this];let e=864e5,r=6e4,n=Rp(this.c),i=this.zone.offset(n-e),o=this.zone.offset(n+e),s=this.zone.offset(n-i*r),a=this.zone.offset(n-o*r);if(s===a)return[this];let c=n-s*r,u=n-a*r,l=yp(c,s),d=yp(u,a);return l.hour===d.hour&&l.minute===d.minute&&l.second===d.second&&l.millisecond===d.millisecond?[sa(this,{ts:c}),sa(this,{ts:u})]:[this]}get isInLeapYear(){return Sl(this.year)}get daysInMonth(){return vp(this.year,this.month)}get daysInYear(){return this.isValid?bc(this.year):NaN}get weeksInWeekYear(){return this.isValid?bl(this.weekYear):NaN}get weeksInLocalWeekYear(){return this.isValid?bl(this.localWeekYear,this.loc.getMinDaysInFirstWeek(),this.loc.getStartOfWeek()):NaN}resolvedLocaleOptions(e={}){let{locale:r,numberingSystem:n,calendar:i}=wr.create(this.loc.clone(e),e).resolvedOptions(this);return{locale:r,numberingSystem:n,outputCalendar:i}}toUTC(e=0,r={}){return this.setZone(_r.instance(e),r)}toLocal(){return this.setZone(Je.defaultZone)}setZone(e,{keepLocalTime:r=!1,keepCalendarTime:n=!1}={}){if(e=is(e,Je.defaultZone),e.equals(this.zone))return this;if(e.isValid){let i=this.ts;if(r||n){let o=e.offset(this.ts),s=this.toObject();[i]=Ip(s,o,e)}return sa(this,{ts:i,zone:e})}else return t.invalid(yl(e))}reconfigure({locale:e,numberingSystem:r,outputCalendar:n}={}){let i=this.loc.clone({locale:e,numberingSystem:r,outputCalendar:n});return sa(this,{loc:i})}setLocale(e){return this.reconfigure({locale:e})}set(e){if(!this.isValid)return this;let r=_p(e,TD),{minDaysInFirstWeek:n,startOfWeek:i}=gD(r,this.loc),o=!pe(r.weekYear)||!pe(r.weekNumber)||!pe(r.weekday),s=!pe(r.ordinal),a=!pe(r.year),c=!pe(r.month)||!pe(r.day),u=a||c,l=r.weekYear||r.weekNumber;if((u||s)&&l)throw new os("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(c&&s)throw new os("Can't mix ordinal dates with month/day");let d;o?d=fD({...Qp(this.c,n,i),...r},n,i):pe(r.ordinal)?(d={...this.toObject(),...r},pe(r.day)&&(d.day=Math.min(vp(d.year,d.month),d.day))):d=hD({...qE(this.c),...r});let[A,p]=Ip(d,this.o,this.zone);return sa(this,{ts:A,o:p})}plus(e){if(!this.isValid)return this;let r=bt.fromDurationLike(e);return sa(this,_D(this,r))}minus(e){if(!this.isValid)return this;let r=bt.fromDurationLike(e).negate();return sa(this,_D(this,r))}startOf(e,{useLocaleWeeks:r=!1}={}){if(!this.isValid)return this;let n={},i=bt.normalizeUnit(e);switch(i){case"years":n.month=1;case"quarters":case"months":n.day=1;case"weeks":case"days":n.hour=0;case"hours":n.minute=0;case"minutes":n.second=0;case"seconds":n.millisecond=0;break}if(i==="weeks")if(r){let o=this.loc.getStartOfWeek(),{weekday:s}=this;s<o&&(n.weekNumber=this.weekNumber-1),n.weekday=o}else n.weekday=1;if(i==="quarters"){let o=Math.ceil(this.month/3);n.month=(o-1)*3+1}return this.set(n)}endOf(e,r){return this.isValid?this.plus({[e]:1}).startOf(e,r).minus(1):this}toFormat(e,r={}){return this.isValid?wr.create(this.loc.redefaultToEN(r)).formatDateTimeFromString(this,e):zE}toLocaleString(e=Bp,r={}){return this.isValid?wr.create(this.loc.clone(r),e).formatDateTime(this):zE}toLocaleParts(e={}){return this.isValid?wr.create(this.loc.clone(e),e).formatDateTimeParts(this):[]}toISO({format:e="extended",suppressSeconds:r=!1,suppressMilliseconds:n=!1,includeOffset:i=!0,extendedZone:o=!1,precision:s="milliseconds"}={}){if(!this.isValid)return null;s=bp(s);let a=e==="extended",c=VE(this,a,s);return Cp.indexOf(s)>=3&&(c+="T"),c+=DD(this,a,r,n,i,o,s),c}toISODate({format:e="extended",precision:r="day"}={}){return this.isValid?VE(this,e==="extended",bp(r)):null}toISOWeekDate(){return Ep(this,"kkkk-'W'WW-c")}toISOTime({suppressMilliseconds:e=!1,suppressSeconds:r=!1,includeOffset:n=!0,includePrefix:i=!1,extendedZone:o=!1,format:s="extended",precision:a="milliseconds"}={}){return this.isValid?(a=bp(a),(i&&Cp.indexOf(a)>=3?"T":"")+DD(this,s==="extended",r,e,n,o,a)):null}toRFC2822(){return Ep(this,"EEE, dd LLL yyyy HH:mm:ss ZZZ",!1)}toHTTP(){return Ep(this.toUTC(),"EEE, dd LLL yyyy HH:mm:ss 'GMT'")}toSQLDate(){return this.isValid?VE(this,!0):null}toSQLTime({includeOffset:e=!0,includeZone:r=!1,includeOffsetSpace:n=!0}={}){let i="HH:mm:ss.SSS";return(r||e)&&(n&&(i+=" "),r?i+="z":e&&(i+="ZZ")),Ep(this,i,!0)}toSQL(e={}){return this.isValid?`${this.toSQLDate()} ${this.toSQLTime(e)}`:null}toString(){return this.isValid?this.toISO():zE}[Symbol.for("nodejs.util.inspect.custom")](){return this.isValid?`DateTime { ts: ${this.toISO()}, zone: ${this.zone.name}, locale: ${this.locale} }`:`DateTime { Invalid, reason: ${this.invalidReason} }`}valueOf(){return this.toMillis()}toMillis(){return this.isValid?this.ts:NaN}toSeconds(){return this.isValid?this.ts/1e3:NaN}toUnixInteger(){return this.isValid?Math.floor(this.ts/1e3):NaN}toJSON(){return this.toISO()}toBSON(){return this.toJSDate()}toObject(e={}){if(!this.isValid)return{};let r={...this.c};return e.includeConfig&&(r.outputCalendar=this.outputCalendar,r.numberingSystem=this.loc.numberingSystem,r.locale=this.loc.locale),r}toJSDate(){return new Date(this.isValid?this.ts:NaN)}diff(e,r="milliseconds",n={}){if(!this.isValid||!e.isValid)return bt.invalid("created by diffing an invalid DateTime");let i={locale:this.locale,numberingSystem:this.numberingSystem,...n},o=KZ(r).map(bt.normalizeUnit),s=e.valueOf()>this.valueOf(),a=s?this:e,c=s?e:this,u=tK(a,c,o,i);return s?u.negate():u}diffNow(e="milliseconds",r={}){return this.diff(t.now(),e,r)}until(e){return this.isValid?ua.fromDateTimes(this,e):this}hasSame(e,r,n){if(!this.isValid)return!1;let i=e.valueOf(),o=this.setZone(e.zone,{keepLocalTime:!0});return o.startOf(r,n)<=i&&i<=o.endOf(r,n)}equals(e){return this.isValid&&e.isValid&&this.valueOf()===e.valueOf()&&this.zone.equals(e.zone)&&this.loc.equals(e.loc)}toRelative(e={}){if(!this.isValid)return null;let r=e.base||t.fromObject({},{zone:this.zone}),n=e.padding?this<r?-e.padding:e.padding:0,i=["years","months","days","hours","minutes","seconds"],o=e.unit;return Array.isArray(e.unit)&&(i=e.unit,o=void 0),ND(r,this.plus(n),{...e,numeric:"always",units:i,unit:o})}toRelativeCalendar(e={}){return this.isValid?ND(e.base||t.fromObject({},{zone:this.zone}),this,{...e,numeric:"auto",units:["years","months","days"],calendary:!0}):null}static min(...e){if(!e.every(t.isDateTime))throw new _t("min requires all arguments be DateTimes");return mD(e,r=>r.valueOf(),Math.min)}static max(...e){if(!e.every(t.isDateTime))throw new _t("max requires all arguments be DateTimes");return mD(e,r=>r.valueOf(),Math.max)}static fromFormatExplain(e,r,n={}){let{locale:i=null,numberingSystem:o=null}=n,s=Ge.fromOpts({locale:i,numberingSystem:o,defaultToEN:!0});return DT(s,e,r)}static fromStringExplain(e,r,n={}){return t.fromFormatExplain(e,r,n)}static buildFormatParser(e,r={}){let{locale:n=null,numberingSystem:i=null}=r,o=Ge.fromOpts({locale:n,numberingSystem:i,defaultToEN:!0});return new Dp(o,e)}static fromFormatParser(e,r,n={}){if(pe(e)||pe(r))throw new _t("fromFormatParser requires an input string and a format parser");let{locale:i=null,numberingSystem:o=null}=n,s=Ge.fromOpts({locale:i,numberingSystem:o,defaultToEN:!0});if(!s.equals(r.locale))throw new _t(`fromFormatParser called with a locale of ${s}, but the format parser was created for ${r.locale}`);let{result:a,zone:c,specificOffset:u,invalidReason:l}=r.explainFromTokens(e);return l?t.invalid(l):Cc(a,c,n,`format ${r.format}`,e,u)}static get DATE_SHORT(){return Bp}static get DATE_MED(){return OD}static get DATE_MED_WITH_WEEKDAY(){return DZ}static get DATE_FULL(){return UD}static get DATE_HUGE(){return MD}static get TIME_SIMPLE(){return xD}static get TIME_WITH_SECONDS(){return LD}static get TIME_WITH_SHORT_OFFSET(){return PD}static get TIME_WITH_LONG_OFFSET(){return FD}static get TIME_24_SIMPLE(){return $D}static get TIME_24_WITH_SECONDS(){return jD}static get TIME_24_WITH_SHORT_OFFSET(){return qD}static get TIME_24_WITH_LONG_OFFSET(){return HD}static get DATETIME_SHORT(){return zD}static get DATETIME_SHORT_WITH_SECONDS(){return GD}static get DATETIME_MED(){return YD}static get DATETIME_MED_WITH_SECONDS(){return VD}static get DATETIME_MED_WITH_WEEKDAY(){return TZ}static get DATETIME_FULL(){return JD}static get DATETIME_FULL_WITH_SECONDS(){return WD}static get DATETIME_HUGE(){return ZD}static get DATETIME_HUGE_WITH_SECONDS(){return KD}};function gl(t){if(Xe.isDateTime(t))return t;if(t&&t.valueOf&&ss(t.valueOf()))return Xe.fromJSDate(t);if(t&&typeof t=="object")return Xe.fromObject(t);throw new _t(`Unknown datetime argument: ${t}, of type ${typeof t}`)}var IK="3.7.2";Dr.DateTime=Xe;Dr.Duration=bt;Dr.FixedOffsetZone=_r;Dr.IANAZone=Co;Dr.Info=ca;Dr.Interval=ua;Dr.InvalidZone=wp;Dr.Settings=Je;Dr.SystemZone=Cl;Dr.VERSION=IK;Dr.Zone=as});var Mp=g(Kt=>{"use strict";Object.defineProperty(Kt,"__esModule",{value:!0});Kt.CronDate=Kt.DAYS_IN_MONTH=Kt.DateMathOp=Kt.TimeUnit=void 0;var la=kT(),Pt;(function(t){t.Second="Second",t.Minute="Minute",t.Hour="Hour",t.Day="Day",t.Month="Month",t.Year="Year"})(Pt||(Kt.TimeUnit=Pt={}));var Op;(function(t){t.Add="Add",t.Subtract="Subtract"})(Op||(Kt.DateMathOp=Op={}));Kt.DAYS_IN_MONTH=Object.freeze([31,29,31,30,31,30,31,31,30,31,30,31]);var Up=class t{#e;#t=null;#n=null;#i={add:{[Pt.Year]:this.addYear.bind(this),[Pt.Month]:this.addMonth.bind(this),[Pt.Day]:this.addDay.bind(this),[Pt.Hour]:this.addHour.bind(this),[Pt.Minute]:this.addMinute.bind(this),[Pt.Second]:this.addSecond.bind(this)},subtract:{[Pt.Year]:this.subtractYear.bind(this),[Pt.Month]:this.subtractMonth.bind(this),[Pt.Day]:this.subtractDay.bind(this),[Pt.Hour]:this.subtractHour.bind(this),[Pt.Minute]:this.subtractMinute.bind(this),[Pt.Second]:this.subtractSecond.bind(this)}};constructor(e,r){let n={zone:r};if(e?e instanceof t?(this.#e=e.#e,this.#t=e.#t,this.#n=e.#n):e instanceof Date?this.#e=la.DateTime.fromJSDate(e,n):typeof e=="number"?this.#e=la.DateTime.fromMillis(e,n):(this.#e=la.DateTime.fromISO(e,n),this.#e.isValid||(this.#e=la.DateTime.fromRFC2822(e,n)),this.#e.isValid||(this.#e=la.DateTime.fromSQL(e,n)),this.#e.isValid||(this.#e=la.DateTime.fromFormat(e,"EEE, d MMM yyyy HH:mm:ss",n))):this.#e=la.DateTime.local(),!this.#e.isValid)throw new Error(`CronDate: unhandled timestamp: ${e}`);r&&r!==this.#e.zoneName&&(this.#e=this.#e.setZone(r))}static#o(e){return e%4===0&&e%100!==0||e%400===0}get dstStart(){return this.#t}set dstStart(e){this.#t=e}get dstEnd(){return this.#n}set dstEnd(e){this.#n=e}addYear(){this.#e=this.#e.plus({years:1})}addMonth(){this.#e=this.#e.plus({months:1}).startOf("month")}addDay(){this.#e=this.#e.plus({days:1}).startOf("day")}addHour(){this.#e=this.#e.plus({hours:1}).startOf("hour")}addMinute(){this.#e=this.#e.plus({minutes:1}).startOf("minute")}addSecond(){this.#e=this.#e.plus({seconds:1})}subtractYear(){this.#e=this.#e.minus({years:1})}subtractMonth(){this.#e=this.#e.minus({months:1}).endOf("month").startOf("second")}subtractDay(){this.#e=this.#e.minus({days:1}).endOf("day").startOf("second")}subtractHour(){this.#e=this.#e.minus({hours:1}).endOf("hour").startOf("second")}subtractMinute(){this.#e=this.#e.minus({minutes:1}).endOf("minute").startOf("second")}subtractSecond(){this.#e=this.#e.minus({seconds:1})}addUnit(e){this.#i.add[e]()}subtractUnit(e){this.#i.subtract[e]()}invokeDateOperation(e,r){if(e===Op.Add){this.addUnit(r);return}if(e===Op.Subtract){this.subtractUnit(r);return}throw new Error(`Invalid verb: ${e}`)}getDate(){return this.#e.day}getFullYear(){return this.#e.year}getDay(){let e=this.#e.weekday;return e===7?0:e}getMonth(){return this.#e.month-1}getHours(){return this.#e.hour}getMinutes(){return this.#e.minute}getSeconds(){return this.#e.second}getMilliseconds(){return this.#e.millisecond}getUTCOffset(){return this.#e.offset}setStartOfDay(){this.#e=this.#e.startOf("day")}setEndOfDay(){this.#e=this.#e.endOf("day")}getTime(){return this.#e.valueOf()}getUTCDate(){return this.#r().day}getUTCFullYear(){return this.#r().year}getUTCDay(){let e=this.#r().weekday;return e===7?0:e}getUTCMonth(){return this.#r().month-1}getUTCHours(){return this.#r().hour}getUTCMinutes(){return this.#r().minute}getUTCSeconds(){return this.#r().second}toISOString(){return this.#e.toUTC().toISO()}toJSON(){return this.#e.toJSON()}setDate(e){this.#e=this.#e.set({day:e})}setFullYear(e){this.#e=this.#e.set({year:e})}setDay(e){this.#e=this.#e.set({weekday:e})}setMonth(e){this.#e=this.#e.set({month:e+1})}setHours(e){this.#e=this.#e.set({hour:e})}setMinutes(e){this.#e=this.#e.set({minute:e})}setSeconds(e){this.#e=this.#e.set({second:e})}setMilliseconds(e){this.#e=this.#e.set({millisecond:e})}toString(){return this.toDate().toString()}toDate(){return this.#e.toJSDate()}isLastDayOfMonth(){let{day:e,month:r}=this.#e;if(r===2){let n=t.#o(this.#e.year);return e===Kt.DAYS_IN_MONTH[r-1]-(n?0:1)}return e===Kt.DAYS_IN_MONTH[r-1]}isLastWeekdayOfMonth(){let{day:e,month:r}=this.#e,n;return r===2?n=Kt.DAYS_IN_MONTH[r-1]-(t.#o(this.#e.year)?0:1):n=Kt.DAYS_IN_MONTH[r-1],e>n-7}applyDateOperation(e,r,n){if(r===Pt.Month||r===Pt.Day){this.invokeDateOperation(e,r);return}let i=this.getHours();this.invokeDateOperation(e,r);let o=this.getHours(),s=o-i;s===2?n!==24&&(this.dstStart=o):s===0&&this.getMinutes()===0&&this.getSeconds()===0&&n!==24&&(this.dstEnd=o)}#r(){return this.#e.toUTC()}};Kt.CronDate=Up;Kt.default=Up});var OT=g(xp=>{"use strict";Object.defineProperty(xp,"__esModule",{value:!0});xp.CronMonth=void 0;var CK=Mp(),bK=rs(),SK=1,BK=12,wK=Object.freeze([]),II=class extends bK.CronField{static get min(){return SK}static get max(){return BK}static get chars(){return wK}static get daysInMonth(){return CK.DAYS_IN_MONTH}constructor(e,r){super(e,r),this.validate()}get values(){return super.values}};xp.CronMonth=II});var UT=g(Lp=>{"use strict";Object.defineProperty(Lp,"__esModule",{value:!0});Lp.CronSecond=void 0;var QK=rs(),vK=0,_K=59,DK=Object.freeze([]),CI=class extends QK.CronField{static get min(){return vK}static get max(){return _K}static get chars(){return DK}constructor(e,r){super(e,r),this.validate()}get values(){return super.values}};Lp.CronSecond=CI});var Pp=g(ar=>{"use strict";var TK=ar&&ar.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),cs=ar&&ar.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&TK(e,t,r)};Object.defineProperty(ar,"__esModule",{value:!0});cs(X0(),ar);cs(eD(),ar);cs(tD(),ar);cs(rs(),ar);cs(rD(),ar);cs(nD(),ar);cs(OT(),ar);cs(UT(),ar)});var SI=g(Fp=>{"use strict";Object.defineProperty(Fp,"__esModule",{value:!0});Fp.CronFieldCollection=void 0;var Kr=Pp(),bI=class t{#e;#t;#n;#i;#o;#r;static from(e,r){return new t({second:this.resolveField(Kr.CronSecond,e.second,r.second),minute:this.resolveField(Kr.CronMinute,e.minute,r.minute),hour:this.resolveField(Kr.CronHour,e.hour,r.hour),dayOfMonth:this.resolveField(Kr.CronDayOfMonth,e.dayOfMonth,r.dayOfMonth),month:this.resolveField(Kr.CronMonth,e.month,r.month),dayOfWeek:this.resolveField(Kr.CronDayOfWeek,e.dayOfWeek,r.dayOfWeek)})}static resolveField(e,r,n){return n?n instanceof Kr.CronField?n:new e(n):r}constructor({second:e,minute:r,hour:n,dayOfMonth:i,month:o,dayOfWeek:s}){if(!e)throw new Error("Validation error, Field second is missing");if(!r)throw new Error("Validation error, Field minute is missing");if(!n)throw new Error("Validation error, Field hour is missing");if(!i)throw new Error("Validation error, Field dayOfMonth is missing");if(!o)throw new Error("Validation error, Field month is missing");if(!s)throw new Error("Validation error, Field dayOfWeek is missing");if(o.values.length===1&&!i.hasLastChar&&!(parseInt(i.values[0],10)<=Kr.CronMonth.daysInMonth[o.values[0]-1]))throw new Error("Invalid explicit day of month definition");this.#e=e,this.#t=r,this.#n=n,this.#o=o,this.#r=s,this.#i=i}get second(){return this.#e}get minute(){return this.#t}get hour(){return this.#n}get dayOfMonth(){return this.#i}get month(){return this.#o}get dayOfWeek(){return this.#r}static compactField(e){if(e.length===0)return[];let r=[],n;return e.forEach((i,o,s)=>{if(n===void 0){n={start:i,count:1};return}let a=s[o-1]||n.start,c=s[o+1];if(i==="L"||i==="W"){r.push(n),r.push({start:i,count:1}),n=void 0;return}if(n.step===void 0&&c!==void 0){let u=i-a,l=c-i;if(u<=l){n={...n,count:2,end:i,step:u};return}n.step=1}i-(n.end??0)===n.step?(n.count++,n.end=i):(n.count===1?r.push({start:n.start,count:1}):n.count===2?(r.push({start:n.start,count:1}),r.push({start:n.end??a,count:1})):r.push(n),n={start:i,count:1})}),n&&r.push(n),r}static#c(e,r,n){let i=r.step;return i?i===1&&r.start===e.min&&r.end&&r.end>=n?e.hasQuestionMarkChar?"?":"*":i!==1&&r.start===e.min&&r.end&&r.end>=n-i+1?`*/${i}`:null:null}static#s(e,r){let n=e.step;if(n===1)return`${e.start}-${e.end}`;let i=e.start===0?e.count-1:e.count;if(!n)throw new Error("Unexpected range step");if(!e.end)throw new Error("Unexpected range end");if(n*i>e.end){let o=(a,c)=>{if(typeof e.start!="number")throw new Error("Unexpected range start");return c%n===0?e.start+c:null};if(typeof e.start!="number")throw new Error("Unexpected range start");let s={length:e.end-e.start+1};return Array.from(s,o).filter(a=>a!==null).join(",")}return e.end===r-n+1?`${e.start}/${n}`:`${e.start}-${e.end}/${n}`}stringifyField(e){let r=e.max,n=e.values;if(e instanceof Kr.CronDayOfWeek){r=6;let o=this.#r.values;n=o[o.length-1]===7?o.slice(0,-1):o}e instanceof Kr.CronDayOfMonth&&(r=this.#o.values.length===1?Kr.CronMonth.daysInMonth[this.#o.values[0]-1]:e.max);let i=t.compactField(n);if(i.length===1){let o=t.#c(e,i[0],r);if(o)return o}return i.map(o=>{let s=o.count===1?o.start.toString():t.#s(o,r);return e instanceof Kr.CronDayOfWeek&&e.nthDay>0?`${s}#${e.nthDay}`:s}).join(",")}stringify(e=!1){let r=[];return e&&r.push(this.stringifyField(this.#e)),r.push(this.stringifyField(this.#t),this.stringifyField(this.#n),this.stringifyField(this.#i),this.stringifyField(this.#o),this.stringifyField(this.#r)),r.join(" ")}serialize(){return{second:this.#e.serialize(),minute:this.#t.serialize(),hour:this.#n.serialize(),dayOfMonth:this.#i.serialize(),month:this.#o.serialize(),dayOfWeek:this.#r.serialize()}}};Fp.CronFieldCollection=bI});var BI=g(Xr=>{"use strict";Object.defineProperty(Xr,"__esModule",{value:!0});Xr.CronExpression=Xr.LOOPS_LIMIT_EXCEEDED_ERROR_MESSAGE=Xr.TIME_SPAN_OUT_OF_BOUNDS_ERROR_MESSAGE=void 0;var ot=Mp();Xr.TIME_SPAN_OUT_OF_BOUNDS_ERROR_MESSAGE="Out of the time span range";Xr.LOOPS_LIMIT_EXCEEDED_ERROR_MESSAGE="Invalid expression, loop limit exceeded";var MT=1e4,$p=class t{#e;#t;#n;#i;#o;#r;#c=null;#s=!1;constructor(e,r){this.#e=r,this.#t=r.tz,this.#i=r.startDate?new ot.CronDate(r.startDate,this.#t):null,this.#o=r.endDate?new ot.CronDate(r.endDate,this.#t):null;let n=r.currentDate??r.startDate;if(n){let i=new ot.CronDate(n,this.#t);this.#i&&i.getTime()<this.#i.getTime()?n=this.#i:this.#o&&i.getTime()>this.#o.getTime()&&(n=this.#o)}this.#n=new ot.CronDate(n,this.#t),this.#r=e}get fields(){return this.#r}static fieldsToExpression(e,r){return new t(e,r||{})}static#a(e,r){return r.some(n=>n===e)}#u(e,r){return e[r?e.length-1:0]}#d(e){let r=`${e.getFullYear()}-${e.getMonth()+1}-${e.getDate()}`;if(this.#c===r)return this.#s;let n=new ot.CronDate(e);n.setStartOfDay();let i=new ot.CronDate(e);return i.setEndOfDay(),this.#c=r,this.#s=n.getUTCOffset()!==i.getUTCOffset(),this.#s}#l(e,r,n){let i=this.#r.second.values,o=e.getSeconds(),s=this.#r.second.findNearestValue(o,n);if(s!==null){e.setSeconds(s);return}e.applyDateOperation(r,ot.TimeUnit.Minute,this.#r.hour.values.length),e.setSeconds(this.#u(i,n))}#A(e,r,n){let i=this.#r.minute.values,o=this.#r.second.values,s=e.getMinutes(),a=this.#r.minute.findNearestValue(s,n);if(a!==null){e.setMinutes(a),e.setSeconds(this.#u(o,n));return}e.applyDateOperation(r,ot.TimeUnit.Hour,this.#r.hour.values.length),e.setMinutes(this.#u(i,n)),e.setSeconds(this.#u(o,n))}static#f(e,r){let n=r.isLastWeekdayOfMonth();return e.some(i=>{let o=parseInt(i.toString().charAt(0),10)%7;if(Number.isNaN(o))throw new Error(`Invalid last weekday of the month expression: ${i}`);return r.getDay()===o&&n})}next(){return this.#g()}prev(){return this.#g(!0)}hasNext(){let e=this.#n;try{return this.#g(),!0}catch{return!1}finally{this.#n=e}}hasPrev(){let e=this.#n;try{return this.#g(!0),!0}catch{return!1}finally{this.#n=e}}take(e){let r=[];if(e>=0)for(let n=0;n<e;n++)try{r.push(this.next())}catch{return r}else for(let n=0;n>e;n--)try{r.push(this.prev())}catch{return r}return r}reset(e){this.#n=new ot.CronDate(e||this.#e.currentDate)}stringify(e=!1){return this.#r.stringify(e)}includesDate(e){let{second:r,minute:n,hour:i,month:o}=this.#r,s=new ot.CronDate(e,this.#t);return!(!r.values.includes(s.getSeconds())||!n.values.includes(s.getMinutes())||!i.values.includes(s.getHours())||!o.values.includes(s.getMonth()+1)||!this.#p(s)||this.#r.dayOfWeek.nthDay>0&&Math.ceil(s.getDate()/7)!==this.#r.dayOfWeek.nthDay)}toString(){return this.#e.expression||this.stringify(!0)}#p(e){let r=this.#r.dayOfMonth.isWildcard,n=!r,i=this.#r.dayOfWeek.isWildcard,o=!i,s=t.#a(e.getDate(),this.#r.dayOfMonth.values)||this.#r.dayOfMonth.hasLastChar&&e.isLastDayOfMonth(),a=t.#a(e.getDay(),this.#r.dayOfWeek.values)||this.#r.dayOfWeek.hasLastChar&&t.#f(this.#r.dayOfWeek.values,e);return!!(n&&o&&(s||a)||s&&!o||r&&!i&&a)}#m(e,r,n){let i=this.#r.hour.values,o=i,s=e.getHours(),a=t.#a(s,i),c=e.dstStart===s,u=e.dstEnd===s;if(c)return t.#a(s-1,i)?!0:(e.invokeDateOperation(r,ot.TimeUnit.Hour),!1);if(u&&!n)return e.dstEnd=null,e.applyDateOperation(ot.DateMathOp.Add,ot.TimeUnit.Hour,o.length),!1;if(a)return!0;e.dstStart=null;let l=this.#r.hour.findNearestValue(s,n);if(l===null)return e.applyDateOperation(r,ot.TimeUnit.Day,o.length),!1;if(this.#d(e)){let d=n?s-l:l-s;for(let A=0;A<d;A++)e.applyDateOperation(r,ot.TimeUnit.Hour,o.length)}else e.setHours(l);return e.setMinutes(this.#u(this.#r.minute.values,n)),e.setSeconds(this.#u(this.#r.second.values,n)),!1}#h(e){if(!this.#i&&!this.#o)return;let r=e.getTime();if(this.#i&&r<this.#i.getTime())throw new Error(Xr.TIME_SPAN_OUT_OF_BOUNDS_ERROR_MESSAGE);if(this.#o&&r>this.#o.getTime())throw new Error(Xr.TIME_SPAN_OUT_OF_BOUNDS_ERROR_MESSAGE)}#g(e=!1){let r=e?ot.DateMathOp.Subtract:ot.DateMathOp.Add,n=new ot.CronDate(this.#n),i=n.getTime(),o=0;for(;++o<MT;){if(this.#h(n),!this.#p(n)){n.applyDateOperation(r,ot.TimeUnit.Day,this.#r.hour.values.length);continue}if(!(this.#r.dayOfWeek.nthDay<=0||Math.ceil(n.getDate()/7)===this.#r.dayOfWeek.nthDay)){n.applyDateOperation(r,ot.TimeUnit.Day,this.#r.hour.values.length);continue}if(!t.#a(n.getMonth()+1,this.#r.month.values)){n.applyDateOperation(r,ot.TimeUnit.Month,this.#r.hour.values.length);continue}if(this.#m(n,r,e)){if(!t.#a(n.getMinutes(),this.#r.minute.values)){this.#A(n,r,e);continue}if(!t.#a(n.getSeconds(),this.#r.second.values)){this.#l(n,r,e);continue}if(i===n.getTime()){(r==="Add"||n.getMilliseconds()===0)&&n.applyDateOperation(r,ot.TimeUnit.Second,this.#r.hour.values.length);continue}break}}if(o>MT)throw new Error(Xr.LOOPS_LIMIT_EXCEEDED_ERROR_MESSAGE);return n.getMilliseconds()!==0&&n.setMilliseconds(0),this.#n=n,n}[Symbol.iterator](){return{next:()=>({value:this.#g(),done:!this.hasNext()})}}};Xr.CronExpression=$p;Xr.default=$p});var xT=g(wI=>{"use strict";Object.defineProperty(wI,"__esModule",{value:!0});wI.seededRandom=kK;function RK(t){let e=2166136261;for(let r=0;r<t.length;r++)e^=t.charCodeAt(r),e=Math.imul(e,16777619);return()=>e>>>0}function NK(t){return()=>{let e=t+=1831565813;return e=Math.imul(e^e>>>15,e|1),e^=e+Math.imul(e^e>>>7,e|61),((e^e>>>14)>>>0)/4294967296}}function kK(t){let e=t?RK(t)():Math.floor(Math.random()*1e10);return NK(e)}});var jp=g(rn=>{"use strict";Object.defineProperty(rn,"__esModule",{value:!0});rn.CronExpressionParser=rn.DayOfWeek=rn.Months=rn.CronUnit=rn.PredefinedExpressions=void 0;var OK=SI(),UK=BI(),MK=xT(),en=Pp(),QI;(function(t){t["@yearly"]="0 0 0 1 1 *",t["@annually"]="0 0 0 1 1 *",t["@monthly"]="0 0 0 1 * *",t["@weekly"]="0 0 0 * * 0",t["@daily"]="0 0 0 * * *",t["@hourly"]="0 0 * * * *",t["@minutely"]="0 * * * * *",t["@secondly"]="* * * * * *",t["@weekdays"]="0 0 0 * * 1-5",t["@weekends"]="0 0 0 * * 0,6"})(QI||(rn.PredefinedExpressions=QI={}));var tn;(function(t){t.Second="Second",t.Minute="Minute",t.Hour="Hour",t.DayOfMonth="DayOfMonth",t.Month="Month",t.DayOfWeek="DayOfWeek"})(tn||(rn.CronUnit=tn={}));var vI;(function(t){t[t.jan=1]="jan",t[t.feb=2]="feb",t[t.mar=3]="mar",t[t.apr=4]="apr",t[t.may=5]="may",t[t.jun=6]="jun",t[t.jul=7]="jul",t[t.aug=8]="aug",t[t.sep=9]="sep",t[t.oct=10]="oct",t[t.nov=11]="nov",t[t.dec=12]="dec"})(vI||(rn.Months=vI={}));var _I;(function(t){t[t.sun=0]="sun",t[t.mon=1]="mon",t[t.tue=2]="tue",t[t.wed=3]="wed",t[t.thu=4]="thu",t[t.fri=5]="fri",t[t.sat=6]="sat"})(_I||(rn.DayOfWeek=_I={}));var DI=class t{static parse(e,r={}){let{strict:n=!1,hashSeed:i}=r,o=(0,MK.seededRandom)(i);e=QI[e]||e;let s=t.#e(e,n);if(!(s.dayOfMonth==="*"||s.dayOfWeek==="*"||!n))throw new Error("Cannot use both dayOfMonth and dayOfWeek together in strict mode!");let a=t.#t(tn.Second,s.second,en.CronSecond.constraints,o),c=t.#t(tn.Minute,s.minute,en.CronMinute.constraints,o),u=t.#t(tn.Hour,s.hour,en.CronHour.constraints,o),l=t.#t(tn.Month,s.month,en.CronMonth.constraints,o),d=t.#t(tn.DayOfMonth,s.dayOfMonth,en.CronDayOfMonth.constraints,o),{dayOfWeek:A,nthDayOfWeek:p}=t.#d(s.dayOfWeek),h=t.#t(tn.DayOfWeek,A,en.CronDayOfWeek.constraints,o),I=new OK.CronFieldCollection({second:new en.CronSecond(a,{rawValue:s.second}),minute:new en.CronMinute(c,{rawValue:s.minute}),hour:new en.CronHour(u,{rawValue:s.hour}),dayOfMonth:new en.CronDayOfMonth(d,{rawValue:s.dayOfMonth}),month:new en.CronMonth(l,{rawValue:s.month}),dayOfWeek:new en.CronDayOfWeek(h,{rawValue:s.dayOfWeek,nthDayOfWeek:p})});return new UK.CronExpression(I,{...r,expression:e})}static#e(e,r){if(r&&!e.length)throw new Error("Invalid cron expression");e=e||"0 * * * * *";let n=e.trim().split(/\s+/);if(r&&n.length<6)throw new Error("Invalid cron expression, expected 6 fields");if(n.length>6)throw new Error("Invalid cron expression, too many fields");let i=["*","*","*","*","*","0"];n.length<i.length&&n.unshift(...i.slice(n.length));let[o,s,a,c,u,l]=n;return{second:o,minute:s,hour:a,dayOfMonth:c,month:u,dayOfWeek:l}}static#t(e,r,n,i){if((e===tn.Month||e===tn.DayOfWeek)&&(r=r.replace(/[a-z]{3}/gi,o=>{o=o.toLowerCase();let s=vI[o]||_I[o];if(s===void 0)throw new Error(`Validation error, cannot resolve alias "${o}"`);return s.toString()})),!n.validChars.test(r))throw new Error(`Invalid characters, got value: ${r}`);return r=this.#n(r,n),r=this.#i(r,n,i),this.#o(e,r,n)}static#n(e,r){return e.replace(/[*?]/g,r.min+"-"+r.max)}static#i(e,r,n){let i=n();return e.replace(/H(?:\((\d+)-(\d+)\))?(?:\/(\d+))?/g,(o,s,a,c)=>{if(s&&a&&c){let u=parseInt(s,10),l=parseInt(a,10),d=parseInt(c,10);if(u>l)throw new Error(`Invalid range: ${u}-${l}, min > max`);if(d<=0)throw new Error(`Invalid step: ${d}, must be positive`);let A=Math.max(u,r.min),p=Math.floor(i*d),h=[];for(let I=Math.floor(A/d)*d+p;I<=l;I+=d)I>=A&&h.push(I);return h.join(",")}else if(s&&a){let u=parseInt(s,10),l=parseInt(a,10);if(u>l)throw new Error(`Invalid range: ${u}-${l}, min > max`);return String(Math.floor(i*(l-u+1))+u)}else if(c){let u=parseInt(c,10);if(u<=0)throw new Error(`Invalid step: ${u}, must be positive`);let l=Math.floor(i*u),d=[];for(let A=Math.floor(r.min/u)*u+l;A<=r.max;A+=u)A>=r.min&&d.push(A);return d.join(",")}else return String(Math.floor(i*(r.max-r.min+1)+r.min))})}static#o(e,r,n){let i=[];function o(a,c){if(Array.isArray(a))i.push(...a);else if(t.#l(c,a))i.push(a);else{let u=parseInt(a.toString(),10);if(!(u>=c.min&&u<=c.max))throw new Error(`Constraint error, got value ${a} expected range ${c.min}-${c.max}`);i.push(e===tn.DayOfWeek?u%7:a)}}return r.split(",").forEach(a=>{if(!(a.length>0))throw new Error("Invalid list value format");o(t.#r(e,a,n),n)}),i}static#r(e,r,n){let i=r.split("/");if(i.length>2)throw new Error(`Invalid repeat: ${r}`);return i.length===2?(isNaN(parseInt(i[0],10))||(i[0]=`${i[0]}-${n.max}`),t.#u(e,i[0],parseInt(i[1],10),n)):t.#u(e,r,1,n)}static#c(e,r,n){if(!(!isNaN(e)&&!isNaN(r)&&e>=n.min&&r<=n.max))throw new Error(`Constraint error, got range ${e}-${r} expected range ${n.min}-${n.max}`);if(e>r)throw new Error(`Invalid range: ${e}-${r}, min(${e}) > max(${r})`)}static#s(e){if(!(!isNaN(e)&&e>0))throw new Error(`Constraint error, cannot repeat at every ${e} time.`)}static#a(e,r,n,i){let o=[];e===tn.DayOfWeek&&n%7===0&&o.push(0);for(let s=r;s<=n;s+=i)o.indexOf(s)===-1&&o.push(s);return o}static#u(e,r,n,i){let o=r.split("-");if(o.length<=1)return isNaN(+r)?r:+r;let[s,a]=o.map(c=>parseInt(c,10));return this.#c(s,a,i),this.#s(n),this.#a(e,s,a,n)}static#d(e){let r=e.split("#");if(r.length<=1)return{dayOfWeek:r[0]};let n=+r[r.length-1],i=e.match(/([,-/])/);if(i!==null)throw new Error(`Constraint error, invalid dayOfWeek \`#\` and \`${i?.[0]}\` special characters are incompatible`);if(!(r.length<=2&&!isNaN(n)&&n>=1&&n<=5))throw new Error("Constraint error, invalid dayOfWeek occurrence number (#)");return{dayOfWeek:r[0],nthDayOfWeek:n}}static#l(e,r){return e.chars.some(n=>r.toString().includes(n))}};rn.CronExpressionParser=DI});var LT=g(qn=>{"use strict";var xK=qn&&qn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),LK=qn&&qn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),PK=qn&&qn.__importStar||(function(){var t=function(e){return t=Object.getOwnPropertyNames||function(r){var n=[];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[n.length]=i);return n},t(e)};return function(e){if(e&&e.__esModule)return e;var r={};if(e!=null)for(var n=t(e),i=0;i<n.length;i++)n[i]!=="default"&&xK(r,e,n[i]);return LK(r,e),r}})();Object.defineProperty(qn,"__esModule",{value:!0});qn.CronFileParser=void 0;var FK=jp(),TI=class t{static async parseFile(e){let{readFile:r}=await Promise.resolve().then(()=>PK(require("fs/promises"))),n=await r(e,"utf8");return t.#e(n)}static parseFileSync(e){let{readFileSync:r}=require("fs"),n=r(e,"utf8");return t.#e(n)}static#e(e){let r=e.split(`
|
|
@@ -728,7 +728,7 @@ REQUIRED GCP PERMISSIONS:
|
|
|
728
728
|
- BigQuery Data Editor (roles/bigquery.dataEditor) - write access
|
|
729
729
|
- BigQuery Job User (roles/bigquery.jobUser) - run queries
|
|
730
730
|
|
|
731
|
-
HEADERS: { "Authorization": "Bearer <<token>>", "Content-Type": "application/json" }`,keywords:["datasets","tables","queries","jobs","projects","schemas","rows","streaming","partitions","clustering","views","routines","models","data warehouse","sql","oauth"]},firebase:{name:"firebase",apiUrl:"https://firestore.googleapis.com",regex:"^.*(firebase|firestore).*$",icon:"firebase",docsUrl:"https://firebase.google.com/docs/reference/firebase-management/rest",openApiUrl:"https://firestore.googleapis.com/$discovery/rest?version=v1",preferredAuthType:"oauth2",oauth:{authUrl:"https://accounts.google.com/o/oauth2/v2/auth",tokenUrl:"https://oauth2.googleapis.com/token",scopes:"https://www.googleapis.com/auth/firebase https://www.googleapis.com/auth/cloud-platform"},keywords:["firestore","realtime database","authentication","cloud functions","storage","hosting","documents","collections","users","projects","apps","query","oauth"]},salesforce:{name:"salesforce",apiUrl:"https://api.salesforce.com",regex:"^.*salesforce.*$",icon:"salesforce",docsUrl:"https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/intro_rest.htm",preferredAuthType:"oauth2",oauth:{authUrl:"https://login.salesforce.com/services/oauth2/authorize",tokenUrl:"https://login.salesforce.com/services/oauth2/token",scopes:"full",grant_type:"authorization_code",managed:!0},keywords:["accounts","contacts","leads","opportunities","cases","campaigns","products","price books","quotes","contracts","orders","custom objects","soql","query","search","sobjects","oauth"]},facebook:{name:"facebook",apiUrl:"https://graph.facebook.com",regex:"^.*facebook.*$",icon:"facebook",docsUrl:"https://developers.facebook.com/docs/graph-api",preferredAuthType:"oauth2",oauth:{authUrl:"https://www.facebook.com/v18.0/dialog/oauth",tokenUrl:"https://graph.facebook.com/v18.0/oauth/access_token",scopes:"email public_profile pages_show_list pages_read_engagement pages_manage_metadata pages_read_user_content pages_manage_posts pages_manage_engagement business_management ads_management ads_read catalog_management leads_retrieval"},keywords:["pages","posts","comments","insights","ads","campaigns","audiences","business","catalog","events","groups","photos","videos","live videos","oauth"]},meta_ads:{name:"meta_ads",apiUrl:"https://graph.facebook.com",regex:"^.*(meta[_ .-]?ads|facebook[_ .-]?ads|marketing[_ .-]?api|/act_).*$",icon:"meta",docsUrl:"https://developers.facebook.com/docs/marketing-api/",preferredAuthType:"oauth2",oauth:{authUrl:"https://www.facebook.com/v23.0/dialog/oauth",tokenUrl:"https://graph.facebook.com/v23.0/oauth/access_token",scopes:"ads_read ads_management business_management"},keywords:["meta ads","facebook ads","marketing api","ad accounts","campaigns","adsets","ads","adcreatives","insights","custom audiences","pixels","leadgen forms","product catalogs","spend","reach","oauth"],systemSpecificInstructions:"Ad account IDs are prefixed with act_ in all request paths (e.g. /v23.0/act_<ACCOUNT_ID>/insights, /act_<ACCOUNT_ID>/campaigns) \u2014 the numeric ID alone fails. With Standard Access, ads_read/ads_management only work for users who hold a role on the Meta app (suitable for development); serving arbitrary users requires Advanced Access, which needs business verification and App Review. For unattended server-to-server use, Business Manager system user tokens are the standard approach instead of user OAuth tokens. Graph API versions sunset roughly two years after release \u2014 prefer the latest version in paths rather than copying versions from older examples."},instagram:{name:"instagram",apiUrl:"https://graph.facebook.com/v23.0/",regex:"^.*instagram.*$",icon:"instagram",docsUrl:"https://developers.facebook.com/docs/instagram-platform/",preferredAuthType:"oauth2",oauth:{authUrl:"https://www.facebook.com/v23.0/dialog/oauth",tokenUrl:"https://graph.facebook.com/v23.0/oauth/access_token",scopes:"instagram_basic pages_show_list instagram_content_publish pages_read_engagement instagram_manage_comments instagram_manage_insights instagram_manage_messages business_management"},keywords:["instagram","instagram api","instagram graph api","media","posts","stories","comments","insights","hashtags","mentions","business discovery","content publishing","user media","account info","oauth"],systemSpecificInstructions:"There are two distinct Instagram APIs: this template targets the Instagram API with Facebook Login (host graph.facebook.com), which requires an Instagram professional (Business/Creator) account linked to a Facebook Page; hashtag search and business discovery are only available on this variant. The alternative Instagram API with Instagram Login uses host graph.instagram.com, needs no Facebook Page, and uses different tokens/scopes. The legacy Instagram Basic Display API was shut down in December 2024 and cannot be used."},twitter:{name:"twitter",apiUrl:"https://api.twitter.com",regex:"^https?:\\/\\/(?:[^/]+\\.)*(?:twitter\\.com|x\\.com)(?:[:/?#].*)?$",icon:"x",docsUrl:"https://docs.x.com/x-api/introduction",openApiUrl:"https://api.x.com/2/openapi.json",preferredAuthType:"oauth2",oauth:{authUrl:"https://twitter.com/i/oauth2/authorize",tokenUrl:"https://api.twitter.com/2/oauth2/token",scopes:"tweet.read tweet.write users.read follows.read follows.write offline.access like.read like.write list.read list.write block.read block.write bookmark.read bookmark.write mute.read mute.write"},keywords:["tweets","users","followers","timeline","mentions","retweets","likes","lists","spaces","direct messages","trends","media","polls","oauth"]},linkedin:{name:"linkedin",apiUrl:"https://api.linkedin.com",regex:"^.*linkedin.*$",icon:"/logos/linkedin.svg",docsUrl:"https://learn.microsoft.com/en-us/linkedin/shared/authentication/getting-access",preferredAuthType:"oauth2",oauth:{authUrl:"https://www.linkedin.com/oauth/v2/authorization",tokenUrl:"https://www.linkedin.com/oauth/v2/accessToken",scopes:"r_liteprofile r_emailaddress w_member_social r_fullprofile r_basicprofile rw_company_admin r_1st_connections r_ads r_ads_reporting r_organization_social rw_organization_admin w_organization_social r_events"},keywords:["profiles","connections","companies","shares","posts","articles","jobs","skills","endorsements","recommendations","groups","events","messaging","oauth"]},paypal:{name:"paypal",apiUrl:"https://api.paypal.com",regex:"^.*paypal.*$",icon:"paypal",docsUrl:"https://developer.paypal.com/api/rest",preferredAuthType:"api_key",keywords:["payments","orders","captures","refunds","payouts","invoices","subscriptions","plans","products","transactions","balances","webhooks","checkout","billing","query","search"]},square:{name:"square",apiUrl:"https://connect.squareup.com",regex:"^.*(square|squareup).*$",icon:"square",docsUrl:"https://developer.squareup.com/reference/square",openApiUrl:"https://raw.githubusercontent.com/square/connect-api-specification/refs/heads/master/api.json",preferredAuthType:"oauth2",oauth:{authUrl:"https://connect.squareup.com/oauth2/authorize",tokenUrl:"https://connect.squareup.com/oauth2/token",scopes:"MERCHANT_PROFILE_READ PAYMENTS_READ PAYMENTS_WRITE CUSTOMERS_READ CUSTOMERS_WRITE INVENTORY_READ INVENTORY_WRITE ORDERS_READ ORDERS_WRITE ITEMS_READ ITEMS_WRITE EMPLOYEES_READ EMPLOYEES_WRITE TIMECARDS_READ TIMECARDS_WRITE"},keywords:["payments","customers","orders","catalog","inventory","locations","transactions","refunds","cards","checkout","invoices","subscriptions","terminals","employees","shifts","query","search","oauth"]},adyen:{name:"adyen",apiUrl:"https://checkout-test.adyen.com",regex:"^.*adyen.*$",icon:"adyen",docsUrl:"https://docs.adyen.com/api-explorer",openApiUrl:"https://raw.githubusercontent.com/Adyen/adyen-openapi/main/yaml/CheckoutService-v71.yaml",preferredAuthType:"api_key",keywords:["paymentMethods","sessions","payments","payments.details","cardDetails","recurringContracts","payouts","balanceTransfers","legalEntities","binLookup","storedValueCards","transferRules","terminalManagement","accountHolders","issuers"]},razorpay:{name:"razorpay",apiUrl:"https://api.razorpay.com",regex:"^.*razorpay.*$",icon:"razorpay",docsUrl:"https://razorpay.com/docs/api",preferredAuthType:"api_key",keywords:["payments","orders","customers","refunds","invoices","subscriptions","accounts","fund_accounts","payouts","virtual_accounts","mandates","disputes","settlements","payment_links","bin_lookup"]},plaid:{name:"plaid",apiUrl:"https://production.plaid.com",regex:"^.*plaid.*$",icon:"/logos/plaid.svg",docsUrl:"https://plaid.com/docs/api",openApiUrl:"https://raw.githubusercontent.com/plaid/plaid-openapi/master/2020-09-14.yml",preferredAuthType:"api_key",keywords:["items","accounts","institutions","link_tokens","access_tokens","transactions","auth","identity","assets","liabilities","income","user","processor_tokens","transfer","investments"]},zendesk:{name:"zendesk",apiUrl:"https://api.zendesk.com",regex:"^.*zendesk.*$",icon:"zendesk",docsUrl:"https://developer.zendesk.com/api-reference",openApiUrl:"https://developer.zendesk.com/zendesk/oas.yaml",preferredAuthType:"api_key",oauth:{authUrl:"https://{subdomain}.zendesk.com/oauth/authorizations/new",tokenUrl:"https://{subdomain}.zendesk.com/oauth/tokens",scopes:"read write tickets:read tickets:write users:read users:write organizations:read organizations:write hc:read hc:write chat:read chat:write"},keywords:["tickets","users","organizations","groups","agents","views","macros","triggers","automations","sla","custom fields","tags","satisfaction","help center","api key"]},freshdesk:{name:"freshdesk",apiUrl:"https://{domain}.freshdesk.com/api/v2",regex:"^.*freshdesk.*$",icon:"/logos/freshdesk.svg",docsUrl:"https://developers.freshdesk.com/api",preferredAuthType:"api_key",keywords:["tickets","contacts","agents","companies","groups","forums","solutions","categories","folders","articles","time entries","surveys","satisfaction","sla","escalations","api key"]},freshworks:{name:"freshworks",apiUrl:"https://{domain}.freshservice.com/api/v2",regex:"^.*(freshworks|freshservice).*$",icon:"/logos/freshworks.svg",docsUrl:"https://api.freshservice.com",preferredAuthType:"api_key",keywords:["tickets","requesters","agents","assets","changes","problems","releases","service catalog","service items","departments","locations","products","vendors","contracts","api key"]},servicenow:{name:"servicenow",apiUrl:"https://{instance}.service-now.com/api",regex:"^.*(servicenow|service-now).*$",icon:"servicenow",docsUrl:"https://developer.servicenow.com/dev.do#!/reference/api/latest/rest",preferredAuthType:"api_key",keywords:["incidents","problems","changes","requests","users","groups","cmdb","configuration items","service catalog","knowledge","tasks","approvals","sla","workflows","tables","api key"]},helpscout:{name:"helpscout",apiUrl:"https://api.helpscout.net",regex:"^.*helpscout.*$",icon:"helpscout",docsUrl:"https://developer.helpscout.com/mailbox-api",preferredAuthType:"api_key",keywords:["conversations","customers","mailboxes","threads","tags","teams","users","reports","satisfaction","ratings","workflows","saved replies","docs","beacon","api key"]},box:{name:"box",label:"Box",apiUrl:"https://api.box.com/2.0",regex:"^https?:\\/\\/(?:[^/]+\\.)*box\\.com(?:[:/?#].*)?$",icon:"simpleicons:box",docsUrl:"https://developer.box.com/reference/",preferredAuthType:"oauth2",oauth:{authUrl:"https://account.box.com/api/oauth2/authorize",tokenUrl:"https://api.box.com/oauth2/token",scopes:"root_readwrite",managed:!0,tokenAuthMethod:"body",tokenContentType:"form"},systemSpecificInstructions:"superglue provides a managed Box OAuth app; users connect with their Box login and never need to create a Box app or supply a client ID or secret. File uploads go to https://upload.box.com/api/2.0, not the main API host. If authorization fails with an app-not-authorized error, the Box enterprise blocks unpublished apps; a Box admin must enable the app in Admin Console > Apps > Custom Apps Manager using the client ID. Refresh tokens rotate and expire after 60 days without use.",keywords:["files","folders","upload","download","sharing","links","metadata","search","collaborations","comments","tasks","enterprise","content","oauth"]},dropbox:{name:"dropbox",label:"Dropbox",apiUrl:"https://api.dropboxapi.com",regex:"^.*dropbox.*$",icon:"dropbox",docsUrl:"https://www.dropbox.com/developers/documentation/http/documentation",preferredAuthType:"oauth2",oauth:{authUrl:"https://www.dropbox.com/oauth2/authorize?token_access_type=offline",tokenUrl:"https://api.dropboxapi.com/oauth2/token",scopes:"files.metadata.read files.metadata.write files.content.read files.content.write sharing.read sharing.write account_info.read account_info.write",managed:!0,tokenAuthMethod:"body",tokenContentType:"form"},systemSpecificInstructions:"Uses the superglue managed Dropbox OAuth app. Downloads and uploads use https://content.dropboxapi.com/2 with arguments in the Dropbox-API-Arg header.",keywords:["files","folders","upload","download","sharing","links","metadata","search","sync","paper","users","teams","move","copy","delete","oauth"]},mailchimp:{name:"mailchimp",apiUrl:"https://api.mailchimp.com",regex:"^.*mailchimp.*$",icon:"mailchimp",docsUrl:"https://mailchimp.com/developer/marketing/api",openApiUrl:"https://api.mailchimp.com/schema/3.0/Swagger.json",preferredAuthType:"api_key",oauth:{authUrl:"https://login.mailchimp.com/oauth2/authorize",tokenUrl:"https://login.mailchimp.com/oauth2/token",scopes:"audiences:read audiences:write automations:read automations:write campaigns:read campaigns:write conversations:read conversations:write ecommerce:read ecommerce:write files:read files:write lists:read lists:write reports:read templates:read templates:write"},keywords:["lists","campaigns","templates","audiences","members","segments","tags","automations","reports","folders","merge fields","activities","ecommerce","batch","query","api key"]},jira:{name:"jira",label:"Jira",apiUrl:"https://{your-domain}.atlassian.net/rest/api",regex:"^.*(jira|atlassian).*$",icon:"jira",docsUrl:"https://developer.atlassian.com/cloud/jira/platform/rest/v3",openApiUrl:"https://developer.atlassian.com/cloud/jira/platform/swagger-v3.json",preferredAuthType:"oauth2",oauth:{authUrl:"https://auth.atlassian.com/authorize",tokenUrl:"https://auth.atlassian.com/oauth/token",scopes:"read:jira-work write:jira-work read:jira-user write:jira-user read:jira-work-management write:jira-work-management read:servicedesk-request write:servicedesk-request manage:jira-project manage:jira-configuration manage:jira-data-provider offline_access",managed:!0},systemSpecificInstructions:"OAuth access tokens only work against https://api.atlassian.com/ex/jira/{cloudId}/rest/api/3; get the cloud id from GET https://api.atlassian.com/oauth/token/accessible-resources. The /rest/api/3/search endpoint has been deprecated - Use GET /rest/api/3/search/jql with query parameter 'jql' for searching issues. MUST specify a project in the JQL query. Example: GET /rest/api/3/search/jql?jql=project=KAN&maxResults=100. The jql parameter accepts JQL queries like 'project=KEY', 'assignee=currentUser()', 'order by created DESC'. Always URL-encode the jql parameter value.",keywords:["issues","projects","boards","sprints","epics","users","workflows","fields","components","versions","priorities","statuses","comments","attachments","jql","query","search","oauth"]},confluence:{name:"confluence",apiUrl:"https://{your-domain}.atlassian.net/wiki/api/v2",regex:"^.*(confluence|atlassian).*$",icon:"confluence",docsUrl:"https://developer.atlassian.com/cloud/confluence/rest/v2",openApiUrl:"https://dac-static.atlassian.com/cloud/confluence/openapi-v2.v3.json",preferredAuthType:"oauth2",oauth:{authUrl:"https://auth.atlassian.com/authorize",tokenUrl:"https://auth.atlassian.com/oauth/token",scopes:"read:confluence-content.all write:confluence-content read:confluence-space.summary write:confluence-space read:confluence-props write:confluence-props read:confluence-user write:confluence-user read:confluence-groups write:confluence-groups delete:confluence-content delete:confluence-space offline_access",managed:!0},systemSpecificInstructions:"Use the Confluence Cloud REST API v2 under /wiki/api/v2 instead of legacy /wiki/rest/api v1 endpoints when a v2 equivalent exists. With OAuth 2.0, fetch the cloud id from GET https://api.atlassian.com/oauth/token/accessible-resources and use https://api.atlassian.com/ex/confluence/{cloudId}/wiki/api/v2 as the system base URL. V2 list endpoints use cursor-based pagination; follow the Link header or _links.next URL until no next page remains.",keywords:["spaces","pages","content","attachments","comments","labels","templates","blueprints","macros","restrictions","versions","ancestors","descendants","children","oauth"]},quickbooks:{name:"quickbooks",apiUrl:"https://quickbooks.api.intuit.com",regex:"^(?!.*(sandbox|desktop|qbxml)).*(quickbooks|intuit).*$",icon:"quickbooks",docsUrl:"https://developer.intuit.com/app/developer/qbo/docs/api/accounting/most-commonly-used/account",preferredAuthType:"oauth2",oauth:{authUrl:"https://appcenter.intuit.com/connect/oauth2",tokenUrl:"https://oauth.platform.intuit.com/oauth2/v1/tokens/bearer",scopes:"com.intuit.quickbooks.accounting",managed:!0,grant_type:"authorization_code",tokenAuthMethod:"basic_auth",tokenContentType:"form"},keywords:["accounts","invoices","customers","vendors","bills","payments","estimates","purchase orders","sales receipts","credit memos","journal entries","items","tax rates","employees","reports","oauth"],systemSpecificInstructions:"superglue provides a managed Intuit Production OAuth app for live QuickBooks Online companies. Users connect without supplying client credentials. For sandbox companies, use the QuickBooks Sandbox template. Payments or Payroll scopes can cause authorization errors such as access_denied when unavailable to the Intuit app or selected QuickBooks company."},quickbooks_sandbox:{name:"quickbooks_sandbox",label:"QuickBooks Sandbox",apiUrl:"https://sandbox-quickbooks.api.intuit.com",regex:"^.*(sandbox-quickbooks\\.api\\.intuit\\.com|quickbooks.*sandbox|intuit.*sandbox).*$",icon:"quickbooks",docsUrl:"https://developer.intuit.com/app/developer/qbo/docs/api/accounting/most-commonly-used/account",preferredAuthType:"oauth2",oauth:{authUrl:"https://appcenter.intuit.com/connect/oauth2",tokenUrl:"https://oauth.platform.intuit.com/oauth2/v1/tokens/bearer",scopes:"com.intuit.quickbooks.accounting",grant_type:"authorization_code",tokenAuthMethod:"basic_auth",tokenContentType:"form"},keywords:["accounts","invoices","customers","vendors","bills","payments","estimates","purchase orders","sales receipts","credit memos","journal entries","items","tax rates","employees","reports","sandbox","oauth"],systemSpecificInstructions:"Use an Intuit app's Development client ID and client secret. Add the exact superglue OAuth callback URL to that app's Development redirect URIs. This template connects QuickBooks Online sandbox companies only. Payments or Payroll scopes can cause authorization errors such as access_denied when unavailable to the Intuit app or selected QuickBooks company."},ramp:{name:"ramp",apiUrl:"https://api.ramp.com/developer/v1",regex:"(^|.*\\b)(ramp|ramp\\.com|api\\.ramp\\.com|demo-api\\.ramp\\.com)(\\b.*|$)",icon:"ramp",docsUrl:"https://docs.ramp.com/developer-api/v1",openApiUrl:"https://docs.ramp.com/openapi/developer-api.json",preferredAuthType:"oauth2",oauth:{tokenUrl:"https://api.ramp.com/developer/v1/token",scopes:"transactions:read cards:read users:read business:read bills:read reimbursements:read vendors:read accounting:read receipts:read departments:read locations:read limits:read spend_programs:read statements:read transfers:read bank_accounts:read",grant_type:"client_credentials",tokenAuthMethod:"basic_auth",tokenContentType:"form"},keywords:["transactions","cards","users","business","bills","reimbursements","vendors","accounting","receipts","departments","locations","limits","spend_programs","statements","transfers","bank_accounts"],systemSpecificInstructions:`Ramp has separate production and sandbox API hosts. Production calls use https://api.ramp.com/developer/v1; sandbox calls use https://demo-api.ramp.com/developer/v1. Do not use the Ramp web app hosts (app.ramp.com or demo.ramp.com) for API calls.
|
|
731
|
+
HEADERS: { "Authorization": "Bearer <<token>>", "Content-Type": "application/json" }`,keywords:["datasets","tables","queries","jobs","projects","schemas","rows","streaming","partitions","clustering","views","routines","models","data warehouse","sql","oauth"]},firebase:{name:"firebase",apiUrl:"https://firestore.googleapis.com",regex:"^.*(firebase|firestore).*$",icon:"firebase",docsUrl:"https://firebase.google.com/docs/reference/firebase-management/rest",openApiUrl:"https://firestore.googleapis.com/$discovery/rest?version=v1",preferredAuthType:"oauth2",oauth:{authUrl:"https://accounts.google.com/o/oauth2/v2/auth",tokenUrl:"https://oauth2.googleapis.com/token",scopes:"https://www.googleapis.com/auth/firebase https://www.googleapis.com/auth/cloud-platform"},keywords:["firestore","realtime database","authentication","cloud functions","storage","hosting","documents","collections","users","projects","apps","query","oauth"]},salesforce:{name:"salesforce",apiUrl:"https://api.salesforce.com",regex:"^.*salesforce.*$",icon:"salesforce",docsUrl:"https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/intro_rest.htm",preferredAuthType:"oauth2",oauth:{authUrl:"https://login.salesforce.com/services/oauth2/authorize",tokenUrl:"https://login.salesforce.com/services/oauth2/token",scopes:"full",grant_type:"authorization_code",managed:!0},keywords:["accounts","contacts","leads","opportunities","cases","campaigns","products","price books","quotes","contracts","orders","custom objects","soql","query","search","sobjects","oauth"]},facebook:{name:"facebook",apiUrl:"https://graph.facebook.com",regex:"^.*facebook.*$",icon:"facebook",docsUrl:"https://developers.facebook.com/docs/graph-api",preferredAuthType:"oauth2",oauth:{authUrl:"https://www.facebook.com/v18.0/dialog/oauth",tokenUrl:"https://graph.facebook.com/v18.0/oauth/access_token",scopes:"email public_profile pages_show_list pages_read_engagement pages_manage_metadata pages_read_user_content pages_manage_posts pages_manage_engagement business_management ads_management ads_read catalog_management leads_retrieval"},keywords:["pages","posts","comments","insights","ads","campaigns","audiences","business","catalog","events","groups","photos","videos","live videos","oauth"]},meta_ads:{name:"meta_ads",apiUrl:"https://graph.facebook.com",regex:"^.*(meta[_ .-]?ads|facebook[_ .-]?ads|marketing[_ .-]?api|/act_).*$",icon:"meta",docsUrl:"https://developers.facebook.com/docs/marketing-api/",preferredAuthType:"oauth2",oauth:{authUrl:"https://www.facebook.com/v23.0/dialog/oauth",tokenUrl:"https://graph.facebook.com/v23.0/oauth/access_token",scopes:"ads_read ads_management business_management"},keywords:["meta ads","facebook ads","marketing api","ad accounts","campaigns","adsets","ads","adcreatives","insights","custom audiences","pixels","leadgen forms","product catalogs","spend","reach","oauth"],systemSpecificInstructions:"Ad account IDs are prefixed with act_ in all request paths (e.g. /v23.0/act_<ACCOUNT_ID>/insights, /act_<ACCOUNT_ID>/campaigns) \u2014 the numeric ID alone fails. With Standard Access, ads_read/ads_management only work for users who hold a role on the Meta app (suitable for development); serving arbitrary users requires Advanced Access, which needs business verification and App Review. For unattended server-to-server use, Business Manager system user tokens are the standard approach instead of user OAuth tokens. Graph API versions sunset roughly two years after release \u2014 prefer the latest version in paths rather than copying versions from older examples."},instagram:{name:"instagram",apiUrl:"https://graph.facebook.com/v23.0/",regex:"^.*instagram.*$",icon:"instagram",docsUrl:"https://developers.facebook.com/docs/instagram-platform/",preferredAuthType:"oauth2",oauth:{authUrl:"https://www.facebook.com/v23.0/dialog/oauth",tokenUrl:"https://graph.facebook.com/v23.0/oauth/access_token",scopes:"instagram_basic pages_show_list instagram_content_publish pages_read_engagement instagram_manage_comments instagram_manage_insights instagram_manage_messages business_management"},keywords:["instagram","instagram api","instagram graph api","media","posts","stories","comments","insights","hashtags","mentions","business discovery","content publishing","user media","account info","oauth"],systemSpecificInstructions:"There are two distinct Instagram APIs: this template targets the Instagram API with Facebook Login (host graph.facebook.com), which requires an Instagram professional (Business/Creator) account linked to a Facebook Page; hashtag search and business discovery are only available on this variant. The alternative Instagram API with Instagram Login uses host graph.instagram.com, needs no Facebook Page, and uses different tokens/scopes. The legacy Instagram Basic Display API was shut down in December 2024 and cannot be used."},twitter:{name:"twitter",apiUrl:"https://api.twitter.com",regex:"^https?:\\/\\/(?:[^/]+\\.)*(?:twitter\\.com|x\\.com)(?:[:/?#].*)?$",icon:"x",docsUrl:"https://docs.x.com/x-api/introduction",openApiUrl:"https://api.x.com/2/openapi.json",preferredAuthType:"oauth2",oauth:{authUrl:"https://twitter.com/i/oauth2/authorize",tokenUrl:"https://api.twitter.com/2/oauth2/token",scopes:"tweet.read tweet.write users.read follows.read follows.write offline.access like.read like.write list.read list.write block.read block.write bookmark.read bookmark.write mute.read mute.write"},keywords:["tweets","users","followers","timeline","mentions","retweets","likes","lists","spaces","direct messages","trends","media","polls","oauth"]},linkedin:{name:"linkedin",apiUrl:"https://api.linkedin.com",regex:"^.*linkedin.*$",icon:"/logos/linkedin.svg",docsUrl:"https://learn.microsoft.com/en-us/linkedin/shared/authentication/getting-access",preferredAuthType:"oauth2",oauth:{authUrl:"https://www.linkedin.com/oauth/v2/authorization",tokenUrl:"https://www.linkedin.com/oauth/v2/accessToken",scopes:"r_liteprofile r_emailaddress w_member_social r_fullprofile r_basicprofile rw_company_admin r_1st_connections r_ads r_ads_reporting r_organization_social rw_organization_admin w_organization_social r_events"},keywords:["profiles","connections","companies","shares","posts","articles","jobs","skills","endorsements","recommendations","groups","events","messaging","oauth"]},paypal:{name:"paypal",apiUrl:"https://api.paypal.com",regex:"^.*paypal.*$",icon:"paypal",docsUrl:"https://developer.paypal.com/api/rest",preferredAuthType:"api_key",keywords:["payments","orders","captures","refunds","payouts","invoices","subscriptions","plans","products","transactions","balances","webhooks","checkout","billing","query","search"]},square:{name:"square",apiUrl:"https://connect.squareup.com",regex:"^.*(square|squareup).*$",icon:"square",docsUrl:"https://developer.squareup.com/reference/square",openApiUrl:"https://raw.githubusercontent.com/square/connect-api-specification/refs/heads/master/api.json",preferredAuthType:"oauth2",oauth:{authUrl:"https://connect.squareup.com/oauth2/authorize",tokenUrl:"https://connect.squareup.com/oauth2/token",scopes:"MERCHANT_PROFILE_READ PAYMENTS_READ PAYMENTS_WRITE CUSTOMERS_READ CUSTOMERS_WRITE INVENTORY_READ INVENTORY_WRITE ORDERS_READ ORDERS_WRITE ITEMS_READ ITEMS_WRITE EMPLOYEES_READ EMPLOYEES_WRITE TIMECARDS_READ TIMECARDS_WRITE"},keywords:["payments","customers","orders","catalog","inventory","locations","transactions","refunds","cards","checkout","invoices","subscriptions","terminals","employees","shifts","query","search","oauth"]},adyen:{name:"adyen",apiUrl:"https://checkout-test.adyen.com",regex:"^.*adyen.*$",icon:"adyen",docsUrl:"https://docs.adyen.com/api-explorer",openApiUrl:"https://raw.githubusercontent.com/Adyen/adyen-openapi/main/yaml/CheckoutService-v71.yaml",preferredAuthType:"api_key",keywords:["paymentMethods","sessions","payments","payments.details","cardDetails","recurringContracts","payouts","balanceTransfers","legalEntities","binLookup","storedValueCards","transferRules","terminalManagement","accountHolders","issuers"]},razorpay:{name:"razorpay",apiUrl:"https://api.razorpay.com",regex:"^.*razorpay.*$",icon:"razorpay",docsUrl:"https://razorpay.com/docs/api",preferredAuthType:"api_key",keywords:["payments","orders","customers","refunds","invoices","subscriptions","accounts","fund_accounts","payouts","virtual_accounts","mandates","disputes","settlements","payment_links","bin_lookup"]},plaid:{name:"plaid",apiUrl:"https://production.plaid.com",regex:"^.*plaid.*$",icon:"/logos/plaid.svg",docsUrl:"https://plaid.com/docs/api",openApiUrl:"https://raw.githubusercontent.com/plaid/plaid-openapi/master/2020-09-14.yml",preferredAuthType:"api_key",keywords:["items","accounts","institutions","link_tokens","access_tokens","transactions","auth","identity","assets","liabilities","income","user","processor_tokens","transfer","investments"]},zendesk:{name:"zendesk",apiUrl:"https://api.zendesk.com",regex:"^.*zendesk.*$",icon:"zendesk",docsUrl:"https://developer.zendesk.com/api-reference",openApiUrl:"https://developer.zendesk.com/zendesk/oas.yaml",preferredAuthType:"api_key",oauth:{authUrl:"https://{subdomain}.zendesk.com/oauth/authorizations/new",tokenUrl:"https://{subdomain}.zendesk.com/oauth/tokens",scopes:"read write tickets:read tickets:write users:read users:write organizations:read organizations:write hc:read hc:write chat:read chat:write"},keywords:["tickets","users","organizations","groups","agents","views","macros","triggers","automations","sla","custom fields","tags","satisfaction","help center","api key"]},freshdesk:{name:"freshdesk",apiUrl:"https://{domain}.freshdesk.com/api/v2",regex:"^.*freshdesk.*$",icon:"/logos/freshdesk.svg",docsUrl:"https://developers.freshdesk.com/api",preferredAuthType:"api_key",keywords:["tickets","contacts","agents","companies","groups","forums","solutions","categories","folders","articles","time entries","surveys","satisfaction","sla","escalations","api key"]},freshworks:{name:"freshworks",apiUrl:"https://{domain}.freshservice.com/api/v2",regex:"^.*(freshworks|freshservice).*$",icon:"/logos/freshworks.svg",docsUrl:"https://api.freshservice.com",preferredAuthType:"api_key",keywords:["tickets","requesters","agents","assets","changes","problems","releases","service catalog","service items","departments","locations","products","vendors","contracts","api key"]},servicenow:{name:"servicenow",apiUrl:"https://{instance}.service-now.com/api",regex:"^.*(servicenow|service-now).*$",icon:"servicenow",docsUrl:"https://developer.servicenow.com/dev.do#!/reference/api/latest/rest",preferredAuthType:"api_key",keywords:["incidents","problems","changes","requests","users","groups","cmdb","configuration items","service catalog","knowledge","tasks","approvals","sla","workflows","tables","api key"]},helpscout:{name:"helpscout",apiUrl:"https://api.helpscout.net",regex:"^.*helpscout.*$",icon:"helpscout",docsUrl:"https://developer.helpscout.com/mailbox-api",preferredAuthType:"api_key",keywords:["conversations","customers","mailboxes","threads","tags","teams","users","reports","satisfaction","ratings","workflows","saved replies","docs","beacon","api key"]},box:{name:"box",label:"Box",apiUrl:"https://api.box.com/2.0",regex:"^https?:\\/\\/(?:[^/]+\\.)*box\\.com(?:[:/?#].*)?$",icon:"simpleicons:box",docsUrl:"https://developer.box.com/reference/",preferredAuthType:"oauth2",oauth:{authUrl:"https://account.box.com/api/oauth2/authorize",tokenUrl:"https://api.box.com/oauth2/token",scopes:"root_readwrite",managed:!0,tokenAuthMethod:"body",tokenContentType:"form"},systemSpecificInstructions:"superglue provides a managed Box OAuth app; users connect with their Box login and never need to create a Box app or supply a client ID or secret. File uploads go to https://upload.box.com/api/2.0, not the main API host. If authorization fails with an app-not-authorized error, the Box enterprise blocks unpublished apps; a Box admin must enable the app in Admin Console > Apps > Custom Apps Manager using the client ID. Refresh tokens rotate and expire after 60 days without use.",keywords:["files","folders","upload","download","sharing","links","metadata","search","collaborations","comments","tasks","enterprise","content","oauth"]},dropbox:{name:"dropbox",label:"Dropbox",apiUrl:"https://api.dropboxapi.com",regex:"^.*dropbox.*$",icon:"dropbox",docsUrl:"https://www.dropbox.com/developers/documentation/http/documentation",preferredAuthType:"oauth2",oauth:{authUrl:"https://www.dropbox.com/oauth2/authorize?token_access_type=offline",tokenUrl:"https://api.dropboxapi.com/oauth2/token",scopes:"files.metadata.read files.metadata.write files.content.read files.content.write sharing.read sharing.write account_info.read",managed:!0,tokenAuthMethod:"body",tokenContentType:"form"},systemSpecificInstructions:"Uses the superglue managed Dropbox OAuth app. Downloads and uploads use https://content.dropboxapi.com/2 with arguments in the Dropbox-API-Arg header.",keywords:["files","folders","upload","download","sharing","links","metadata","search","sync","paper","users","teams","move","copy","delete","oauth"]},mailchimp:{name:"mailchimp",apiUrl:"https://api.mailchimp.com",regex:"^.*mailchimp.*$",icon:"mailchimp",docsUrl:"https://mailchimp.com/developer/marketing/api",openApiUrl:"https://api.mailchimp.com/schema/3.0/Swagger.json",preferredAuthType:"api_key",oauth:{authUrl:"https://login.mailchimp.com/oauth2/authorize",tokenUrl:"https://login.mailchimp.com/oauth2/token",scopes:"audiences:read audiences:write automations:read automations:write campaigns:read campaigns:write conversations:read conversations:write ecommerce:read ecommerce:write files:read files:write lists:read lists:write reports:read templates:read templates:write"},keywords:["lists","campaigns","templates","audiences","members","segments","tags","automations","reports","folders","merge fields","activities","ecommerce","batch","query","api key"]},jira:{name:"jira",label:"Jira",apiUrl:"https://{your-domain}.atlassian.net/rest/api",regex:"^.*(jira|atlassian).*$",icon:"jira",docsUrl:"https://developer.atlassian.com/cloud/jira/platform/rest/v3",openApiUrl:"https://developer.atlassian.com/cloud/jira/platform/swagger-v3.json",preferredAuthType:"oauth2",oauth:{authUrl:"https://auth.atlassian.com/authorize",tokenUrl:"https://auth.atlassian.com/oauth/token",scopes:"read:jira-work write:jira-work read:jira-user write:jira-user read:jira-work-management write:jira-work-management read:servicedesk-request write:servicedesk-request manage:jira-project manage:jira-configuration manage:jira-data-provider offline_access",managed:!0},systemSpecificInstructions:"OAuth access tokens only work against https://api.atlassian.com/ex/jira/{cloudId}/rest/api/3; get the cloud id from GET https://api.atlassian.com/oauth/token/accessible-resources. The /rest/api/3/search endpoint has been deprecated - Use GET /rest/api/3/search/jql with query parameter 'jql' for searching issues. MUST specify a project in the JQL query. Example: GET /rest/api/3/search/jql?jql=project=KAN&maxResults=100. The jql parameter accepts JQL queries like 'project=KEY', 'assignee=currentUser()', 'order by created DESC'. Always URL-encode the jql parameter value.",keywords:["issues","projects","boards","sprints","epics","users","workflows","fields","components","versions","priorities","statuses","comments","attachments","jql","query","search","oauth"]},confluence:{name:"confluence",apiUrl:"https://{your-domain}.atlassian.net/wiki/api/v2",regex:"^.*(confluence|atlassian).*$",icon:"confluence",docsUrl:"https://developer.atlassian.com/cloud/confluence/rest/v2",openApiUrl:"https://dac-static.atlassian.com/cloud/confluence/openapi-v2.v3.json",preferredAuthType:"oauth2",oauth:{authUrl:"https://auth.atlassian.com/authorize",tokenUrl:"https://auth.atlassian.com/oauth/token",scopes:"read:confluence-content.all write:confluence-content read:confluence-space.summary write:confluence-space read:confluence-props write:confluence-props read:confluence-user write:confluence-user read:confluence-groups write:confluence-groups delete:confluence-content delete:confluence-space offline_access",managed:!0},systemSpecificInstructions:"Use the Confluence Cloud REST API v2 under /wiki/api/v2 instead of legacy /wiki/rest/api v1 endpoints when a v2 equivalent exists. With OAuth 2.0, fetch the cloud id from GET https://api.atlassian.com/oauth/token/accessible-resources and use https://api.atlassian.com/ex/confluence/{cloudId}/wiki/api/v2 as the system base URL. V2 list endpoints use cursor-based pagination; follow the Link header or _links.next URL until no next page remains.",keywords:["spaces","pages","content","attachments","comments","labels","templates","blueprints","macros","restrictions","versions","ancestors","descendants","children","oauth"]},quickbooks:{name:"quickbooks",apiUrl:"https://quickbooks.api.intuit.com",regex:"^(?!.*(sandbox|desktop|qbxml)).*(quickbooks|intuit).*$",icon:"quickbooks",docsUrl:"https://developer.intuit.com/app/developer/qbo/docs/api/accounting/most-commonly-used/account",preferredAuthType:"oauth2",oauth:{authUrl:"https://appcenter.intuit.com/connect/oauth2",tokenUrl:"https://oauth.platform.intuit.com/oauth2/v1/tokens/bearer",scopes:"com.intuit.quickbooks.accounting",managed:!0,grant_type:"authorization_code",tokenAuthMethod:"basic_auth",tokenContentType:"form"},keywords:["accounts","invoices","customers","vendors","bills","payments","estimates","purchase orders","sales receipts","credit memos","journal entries","items","tax rates","employees","reports","oauth"],systemSpecificInstructions:"superglue provides a managed Intuit Production OAuth app for live QuickBooks Online companies. Users connect without supplying client credentials. For sandbox companies, use the QuickBooks Sandbox template. Payments or Payroll scopes can cause authorization errors such as access_denied when unavailable to the Intuit app or selected QuickBooks company."},quickbooks_sandbox:{name:"quickbooks_sandbox",label:"QuickBooks Sandbox",apiUrl:"https://sandbox-quickbooks.api.intuit.com",regex:"^.*(sandbox-quickbooks\\.api\\.intuit\\.com|quickbooks.*sandbox|intuit.*sandbox).*$",icon:"quickbooks",docsUrl:"https://developer.intuit.com/app/developer/qbo/docs/api/accounting/most-commonly-used/account",preferredAuthType:"oauth2",oauth:{authUrl:"https://appcenter.intuit.com/connect/oauth2",tokenUrl:"https://oauth.platform.intuit.com/oauth2/v1/tokens/bearer",scopes:"com.intuit.quickbooks.accounting",grant_type:"authorization_code",tokenAuthMethod:"basic_auth",tokenContentType:"form"},keywords:["accounts","invoices","customers","vendors","bills","payments","estimates","purchase orders","sales receipts","credit memos","journal entries","items","tax rates","employees","reports","sandbox","oauth"],systemSpecificInstructions:"Use an Intuit app's Development client ID and client secret. Add the exact superglue OAuth callback URL to that app's Development redirect URIs. This template connects QuickBooks Online sandbox companies only. Payments or Payroll scopes can cause authorization errors such as access_denied when unavailable to the Intuit app or selected QuickBooks company."},ramp:{name:"ramp",apiUrl:"https://api.ramp.com/developer/v1",regex:"(^|.*\\b)(ramp|ramp\\.com|api\\.ramp\\.com|demo-api\\.ramp\\.com)(\\b.*|$)",icon:"ramp",docsUrl:"https://docs.ramp.com/developer-api/v1",openApiUrl:"https://docs.ramp.com/openapi/developer-api.json",preferredAuthType:"oauth2",oauth:{tokenUrl:"https://api.ramp.com/developer/v1/token",scopes:"transactions:read cards:read users:read business:read bills:read reimbursements:read vendors:read accounting:read receipts:read departments:read locations:read limits:read spend_programs:read statements:read transfers:read bank_accounts:read",grant_type:"client_credentials",tokenAuthMethod:"basic_auth",tokenContentType:"form"},keywords:["transactions","cards","users","business","bills","reimbursements","vendors","accounting","receipts","departments","locations","limits","spend_programs","statements","transfers","bank_accounts"],systemSpecificInstructions:`Ramp has separate production and sandbox API hosts. Production calls use https://api.ramp.com/developer/v1; sandbox calls use https://demo-api.ramp.com/developer/v1. Do not use the Ramp web app hosts (app.ramp.com or demo.ramp.com) for API calls.
|
|
732
732
|
|
|
733
733
|
Create the developer app from the Ramp dashboard's Developer area with an Admin or Business Owner account, enable the Client Credentials grant for internal server-to-server integrations, configure only the required scopes, and copy the client ID and client secret. Sandbox access is not self-serve; the customer must request a sandbox from Ramp, and sandbox credentials do not work in production.
|
|
734
734
|
|
|
@@ -1744,7 +1744,7 @@ ${o}`;break;case"retry":wz(o)&&(r[i]=o);break;case"id":Qz(o)&&(r[i]=o);break;cas
|
|
|
1744
1744
|
`);t.stack=r?`${r}
|
|
1745
1745
|
${o}`:i.stack}Y.exports.fetch=function(e,r=void 0){return eTe(e,r).catch(n=>{throw xz?$z(n,xz):n&&typeof n=="object"&&Error.captureStackTrace(n,Y.exports.fetch),n})};Y.exports.Headers=ec().Headers;Y.exports.Response=SA().Response;Y.exports.Request=Nu().Request;Y.exports.FormData=kg().FormData;var{setGlobalOrigin:tTe,getGlobalOrigin:rTe}=OS();Y.exports.setGlobalOrigin=tTe;Y.exports.getGlobalOrigin=rTe;var{CacheStorage:nTe}=SH(),{kConstruct:iTe}=$e();Y.exports.caches=new nTe(iTe);var{deleteCookie:oTe,getCookies:sTe,getSetCookies:aTe,setCookie:cTe,parseCookie:uTe}=UH();Y.exports.deleteCookie=oTe;Y.exports.getCookies=sTe;Y.exports.getSetCookies=aTe;Y.exports.setCookie=cTe;Y.exports.parseCookie=uTe;var{parseMIMEType:lTe,serializeAMimeType:dTe}=pn();Y.exports.parseMIMEType=lTe;Y.exports.serializeAMimeType=dTe;var{CloseEvent:ATe,ErrorEvent:pTe,MessageEvent:fTe}=Km(),{WebSocket:hTe,ping:gTe}=fz();Y.exports.WebSocket=hTe;Y.exports.CloseEvent=ATe;Y.exports.ErrorEvent=pTe;Y.exports.MessageEvent=fTe;Y.exports.ping=gTe;Y.exports.WebSocketStream=bz().WebSocketStream;Y.exports.WebSocketError=lv().WebSocketError;Y.exports.request=UA(qu.request);Y.exports.stream=UA(qu.stream);Y.exports.pipeline=UA(qu.pipeline);Y.exports.connect=UA(qu.connect);Y.exports.upgrade=UA(qu.upgrade);Y.exports.MockClient=jDe;Y.exports.MockCallHistory=qDe;Y.exports.MockCallHistoryLog=HDe;Y.exports.MockPool=GDe;Y.exports.MockAgent=zDe;Y.exports.SnapshotAgent=YDe;Y.exports.mockErrors=VDe;var{EventSource:mTe}=Mz();Y.exports.EventSource=mTe;function yTe(){globalThis.fetch=Y.exports.fetch,globalThis.Headers=Y.exports.Headers,globalThis.Response=Y.exports.Response,globalThis.Request=Y.exports.Request,globalThis.FormData=Y.exports.FormData,globalThis.WebSocket=Y.exports.WebSocket,globalThis.CloseEvent=Y.exports.CloseEvent,globalThis.ErrorEvent=Y.exports.ErrorEvent,globalThis.MessageEvent=Y.exports.MessageEvent,globalThis.EventSource=Y.exports.EventSource}Y.exports.install=yTe});var Hz=g(zu=>{"use strict";Object.defineProperty(zu,"__esModule",{value:!0});zu.SuperglueClient=zu.SuperglueHttpError=void 0;var Hu=Br(),Go=tb(),ETe=Tb(),ITe=tL(),CTe=Vn(),Yo=kc(),bTe=Gl(),xA=14400*1e3,MA;if(typeof globalThis.process<"u"&&globalThis.process.versions?.node)try{let{Agent:t}=jz();MA=new t({headersTimeout:xA,bodyTimeout:xA})}catch{}function qz(t){if(t?.aborted)throw t.reason??new DOMException("Aborted","AbortError")}var Ay=class extends Error{constructor(e,r,n,i){super(e),this.status=r,this.code=n,this.details=i,this.name="SuperglueHttpError"}};zu.SuperglueHttpError=Ay;var gv=class{constructor({apiKey:e,apiEndpoint:r,onInfrastructureError:n,refreshToken:i,sseTokenProvider:o,tokenProvider:s}){if(!e&&!s)throw new Error("SuperglueClient requires either apiKey or tokenProvider");this.tokenProvider=s??(async()=>e),this.apiEndpoint=r??"https://api.superglue.cloud",this.sseManager=new ETe.SSELogSubscriptionManager(this.apiEndpoint,o??this.tokenProvider,i),this.onInfrastructureError=n,this.refreshToken=i}async getApiKey(){return this.tokenProvider()}async fetchWithAuthRetry(e,r){let n=await this.getApiKey(),i=await e(n);if(i.status!==401||!this.refreshToken)return i;qz(r);let o=await this.refreshToken();return qz(r),!o||o===n?i:(i.body?.cancel(),e(o))}isInfrastructureError(e){return(0,CTe.isAbortError)(e)?!1:!!(e instanceof TypeError&&e.message.toLowerCase().includes("fetch")||e instanceof Error&&e.name==="TimeoutError")}async restRequest(e,r,n,i,o){let a=await(await this.restResponse({method:e,path:r,body:n,extraHeaders:i,requestInit:o})).text();if(a)return JSON.parse(a)}async restResponse({method:e,path:r,body:n,extraHeaders:i,requestInit:o}){let s=`${this.apiEndpoint.replace(/\/$/,"")}${r}`,a=n!=null,c=typeof FormData<"u"&&n instanceof FormData,u=d=>{let A={Authorization:`Bearer ${d}`,...i};return a&&!c&&e!=="GET"&&(A["Content-Type"]="application/json"),fetch(s,{...o,method:e,headers:A,body:a?c?n:JSON.stringify(n):void 0,signal:o?.signal??AbortSignal.timeout(xA),...MA?{dispatcher:MA}:{}})},l;try{l=await this.fetchWithAuthRetry(u,o?.signal)}catch(d){throw this.isInfrastructureError(d)&&this.onInfrastructureError?.(),d}if(!l.ok)throw await this.buildHttpError(l);return l}async uploadFiles(e,r){if(typeof r?.process!="boolean")throw new Error("process must be a boolean");if(e.length===0)return[];let n=e.map(l=>({...l,contentLength:l.contentLength??this.getUploadContentLength(l.content)})),o=(await this.restRequest("POST","/v1/files/uploads",{process:r.process,files:n.map(({fileName:l,contentType:d,contentLength:A})=>({fileName:l,contentLength:A,...d?{contentType:d}:{}}))})).data.files;if(o.length!==n.length)throw await Promise.all(o.map(l=>this.deleteFileUpload(l.id).catch(()=>{}))),new Error("Upload response did not match the selected files");let s=await Promise.allSettled(o.map(async(l,d)=>{let A=n[d],p=await fetch(l.uploadUrl,{method:"PUT",body:A.content,headers:A.contentType?{"Content-Type":A.contentType}:void 0,signal:AbortSignal.timeout(Math.min(xA,l.expiresIn*1e3))});if(!p.ok)throw new Error(`Upload failed for ${A.fileName}: ${p.status} ${p.statusText}`);return l.id})),a=s.flatMap(l=>l.status==="fulfilled"?[l.value]:[]),c=new Map;if(a.length>0)try{let l=await this.restRequest("POST","/v1/files/uploads/complete",{fileIds:a});c=new Map(l.data.files.map(d=>[d.id,d]))}catch(l){c=new Map(a.map(d=>[d,{id:d,fileName:n[o.findIndex(A=>A.id===d)]?.fileName||d,contentLength:n[o.findIndex(A=>A.id===d)]?.contentLength||0,status:"failed",error:l instanceof Error?l.message:String(l)}]))}let u=o.map((l,d)=>{let A=s[d],p=n[d];return A.status==="rejected"?{id:l.id,fileName:p.fileName,contentLength:p.contentLength,status:"failed",error:A.reason instanceof Error?A.reason.message:String(A.reason)}:c.get(l.id)||{id:l.id,fileName:p.fileName,contentLength:p.contentLength,status:"failed",error:"Upload completion returned no result"}});return await Promise.all(u.filter(l=>l.status==="failed").map(l=>this.deleteFileUpload(l.id).catch(()=>{}))),u}async deleteFileUpload(e){await this.restRequest("DELETE",`/v1/files/uploads/${encodeURIComponent(e)}`)}getUploadContentLength(e){return typeof e=="string"?new TextEncoder().encode(e).byteLength:e instanceof Uint8Array?e.byteLength:e.size}async buildHttpError(e){e.status>=500&&this.onInfrastructureError?.();let r=await e.text(),n=`HTTP ${e.status}: ${r}`,i,o;try{let s=JSON.parse(r);s&&typeof s=="object"&&!Array.isArray(s)&&(o=s),typeof s?.code=="string"&&(i=s.code);let a=s.error;typeof a=="string"?n=a:a&&typeof a=="object"&&(n=a.message||JSON.stringify(a))}catch{}return new Ay(n,e.status,i,o)}async streamRequest(e,r,n){let i=e.includes("?")?"&":"?",o=`${this.apiEndpoint.replace(/\/$/,"")}${e}${i}stream=true`,s=u=>fetch(o,{method:"POST",headers:{Authorization:`Bearer ${u}`,Accept:"text/event-stream","Content-Type":"application/json"},body:JSON.stringify(r),signal:n??AbortSignal.timeout(xA),...MA?{dispatcher:MA}:{}}),a;try{a=await this.fetchWithAuthRetry(s,n)}catch(u){throw this.isInfrastructureError(u)&&this.onInfrastructureError?.(),u}if(!a.ok)throw await this.buildHttpError(a);if(!(a.headers.get("content-type")||"").includes("text/event-stream")){let u=await a.text();return u?JSON.parse(u):void 0}try{return await(0,ITe.consumeEventStreamResult)(a)}catch(u){throw this.isInfrastructureError(u)&&this.onInfrastructureError?.(),u}}async subscribeToLogsSSE(e={}){return this.sseManager.subscribeToLogs(e)}async disconnect(){await this.sseManager.disconnect()}async listMemoryNotes(e={}){let r=new URLSearchParams;e.scope&&r.set("scope",e.scope),e.query&&r.set("query",e.query);let n=r.toString();return(await this.restRequest("GET",`/v1/memory-notes${n?`?${n}`:""}`)).data}async createMemoryNote(e){return(await this.restRequest("POST","/v1/memory-notes",e)).data}async updateMemoryNote(e,r){return(await this.restRequest("PATCH",`/v1/memory-notes/${encodeURIComponent(e)}`,r)).data}async deleteMemoryNote(e){await this.restRequest("DELETE",`/v1/memory-notes/${encodeURIComponent(e)}`)}async clearMemoryNotes(e){return(await this.restRequest("DELETE",`/v1/memory-notes?scope=${e}`)).data.deleted}async getMe(){return this.restRequest("GET","/v1/me")}async completeOnboarding(){return this.restRequest("POST","/v1/me/onboarding/complete")}async runTool(e){let r=await this.restRequest("POST",`/v1/tools/${encodeURIComponent(e.toolId)}/run`,{inputs:e.payload,files:e.files,credentials:e.credentials,includeStepResultData:e.includeStepResultData,options:e.options,runId:e.runId,stateFixture:e.stateFixture},void 0,e.signal?{signal:e.signal}:void 0);return{success:r.status==="success",data:r.data,error:r.error,tool:r.tool,stepResults:r.stepResults?.map(n=>({...n}))||[],...r.fileArtifacts&&r.fileArtifacts.length>0?{fileArtifacts:r.fileArtifacts}:{},...r.metadata?.warnings?.length?{warnings:r.metadata.warnings}:{}}}async runToolConfig(e){let r=e.createRun?"/v1/tools/run?createRun=true":"/v1/tools/run",n=await this.restRequest("POST",r,{tool:e.tool,payload:e.payload,files:e.files,credentials:e.credentials,includeStepResultData:e.includeStepResultData,options:e.options,runId:e.runId,stateFixture:e.stateFixture,executionKind:e.executionKind,parentToolId:e.parentToolId,draftId:e.draftId},e.traceId?{"X-Trace-Id":e.traceId}:void 0,e.signal?{signal:e.signal}:void 0);return{success:n.status?n.status==="success":n.success??!1,data:n.data,error:n.error,tool:n.tool||e.tool,stepResults:n.stepResults?.map(o=>({...o}))||[],...n.fileArtifacts&&n.fileArtifacts.length>0?{fileArtifacts:n.fileArtifacts}:{},...n.metadata?.warnings?.length?{warnings:n.metadata.warnings}:{}}}async abortToolExecution(e){return{success:!0,runId:(await this.restRequest("POST",`/v1/runs/${encodeURIComponent(e)}/cancel`)).runId}}async executeStep({step:e,payload:r,files:n,previousResults:i,credentials:o,options:s,runId:a,systemIds:c,createRun:u,parentToolId:l,stepIndex:d,stepId:A,signal:p,stream:h}){let I={step:e,payload:r,files:n,previousResults:i,credentials:o,options:s,runId:a,systemIds:c,createRun:u,parentToolId:l,stepIndex:d,stepId:A};return h?this.streamRequest("/v1/tools/step/run",I,p):this.restRequest("POST","/v1/tools/step/run",I,void 0,p?{signal:p}:void 0)}async abortStep(e){return this.restRequest("POST","/v1/tools/step/abort",{runId:e})}async executeTransformOnly({outputTransform:e,outputSchema:r,inputSchema:n,payload:i,files:o,stepResults:s,options:a,runId:c,createRun:u,parentToolId:l,stepId:d,signal:A,stream:p}){let h={outputTransform:e,outputSchema:r,inputSchema:n,payload:i,files:o,stepResults:s,options:a,runId:c,createRun:u,parentToolId:l,stepId:d};return p?this.streamRequest("/v1/tools/transform/run",h,A):this.restRequest("POST","/v1/tools/transform/run",h,void 0,A?{signal:A}:void 0)}async createRun({toolId:e,toolConfig:r,toolResult:n,stepResults:i,toolPayload:o,status:s,error:a,startedAt:c,completedAt:u,executionKind:l,parentToolId:d,draftId:A}){return this.restRequest("POST","/v1/runs",{toolId:e,toolConfig:r,toolResult:n,stepResults:i,toolPayload:o,status:s,error:a,startedAt:(0,Yo.toUTCISOString)(c,"run.startedAt"),completedAt:(0,Yo.toUTCISOString)(u,"run.completedAt"),executionKind:l,parentToolId:d,draftId:A})}async checkRunLimit(){return(await this.restRequest("POST","/v1/runs/check-limit")).data}async extract({file:e,envelope:r}){if(!e)throw new Error("File must be provided for extract.");let n=new FormData;n.append("file",e);let i=r?"/v1/extract?envelope=true":"/v1/extract";return this.restRequest("POST",i,n)}mapOpenAPIRunToRun(e){let r={running:Hu.RunStatus.RUNNING,success:Hu.RunStatus.SUCCESS,failed:Hu.RunStatus.FAILED,aborted:Hu.RunStatus.ABORTED};return{runId:e.runId??e.id,toolId:e.toolId,tool:e.tool,systemIds:e.systemIds,status:r[e.status]??Hu.RunStatus.FAILED,toolPayload:e.toolPayload,data:e.data,toolResult:e.data,error:e.error,stepResults:e.stepResults,options:e.options,requestSource:e.requestSource,traceId:e.traceId,resultStorageUri:e.resultStorageUri,userId:e.userId,userEmail:e.userEmail,userName:e.userName,metadata:{...e.metadata,executionKind:e.metadata?.executionKind??Hu.RunExecutionKind.FULL},fileArtifacts:e.fileArtifacts}}mapOpenAPIScheduleToToolSchedule(e){return{...e,lastRunAt:e.lastRunAt?(0,Yo.requireUTCDate)(e.lastRunAt,"schedule.lastRunAt"):void 0,nextRunAt:(0,Yo.requireUTCDate)(e.nextRunAt,"schedule.nextRunAt"),createdAt:(0,Yo.requireUTCDate)(e.createdAt,"schedule.createdAt"),updatedAt:(0,Yo.requireUTCDate)(e.updatedAt,"schedule.updatedAt")}}async listRuns(e={}){let r=(0,Go.createSearchListQueryParams)(e);e.toolId!==void 0&&r.set("toolId",e.toolId),e.searchUserIds?.length&&r.set("searchUserIds",e.searchUserIds.join(",")),e.includeTotal!==void 0&&r.set("includeTotal",String(e.includeTotal)),e.startedAfter!==void 0&&r.set("startedAfter",e.startedAfter instanceof Date?(0,Yo.toUTCISOString)(e.startedAfter,"run.startedAfter"):e.startedAfter),e.statuses!==void 0?r.set("status",e.statuses.join(",")):e.status!==void 0&&r.set("status",e.status),e.requestSources!==void 0&&r.set("requestSources",e.requestSources.join(",")),e.executionKinds!==void 0&&r.set("executionKinds",e.executionKinds.join(",")),e.userId!==void 0&&r.set("userId",e.userId),e.systemId!==void 0&&r.set("systemId",e.systemId),e.systemIds!==void 0&&r.set("systemIds",e.systemIds.join(","));let n=r.size>0?`?${r.toString()}`:"",i=await this.restRequest("GET",`/v1/runs${n}`,void 0,void 0,{signal:e.signal});return{data:i.data.map(o=>this.mapOpenAPIRunToRun(o)),total:i.total,page:i.page,limit:i.limit,hasMore:i.hasMore}}async getActivityCounts(e){let r=new URLSearchParams;e?.from&&r.set("from",e.from instanceof Date?(0,Yo.toUTCISOString)(e.from,"activity.from"):e.from),e?.to&&r.set("to",e.to instanceof Date?(0,Yo.toUTCISOString)(e.to,"activity.to"):e.to);let n=r.toString();return(await this.restRequest("GET",`/v1/activity/counts${n?`?${n}`:""}`,void 0,void 0,{signal:e?.signal})).counts}async getRun(e){try{let r=await this.restRequest("GET",`/v1/runs/${encodeURIComponent(e)}`);return this.mapOpenAPIRunToRun(r)}catch(r){if(r.message?.includes("404")||r.message?.includes("not found"))return null;throw r}}async getTool(e){try{return await this.restRequest("GET",`/v1/tools/${encodeURIComponent(e)}`)}catch(r){if(r.message?.includes("404")||r.message?.includes("not found")||r.message?.includes("403")||r.message?.includes("not allowed"))return null;throw r}}async getToolState(e){return(await this.restRequest("GET",`/v1/tools/${encodeURIComponent(e)}/state`)).state}async setToolState(e,r){await this.restRequest("PUT",`/v1/tools/${encodeURIComponent(e)}/state`,{state:r})}async deleteToolState(e){return(await this.restRequest("DELETE",`/v1/tools/${encodeURIComponent(e)}/state`)).deletedKeys}async archiveTool(e,r=!0){return this.updateTool(e,{archived:r})}async bulkArchiveTools(e,r=!0){return this.restRequest("POST","/v1/tools/bulk/archive",{ids:e,archived:r})}async bulkDeleteTools(e){return this.restRequest("POST","/v1/tools/bulk/delete",{ids:e})}async listTools(e={}){let r=(0,Go.createListQueryParams)(e);e.includeArchived!==void 0&&r.set("includeArchived",String(e.includeArchived));let n=r.size>0?`?${r.toString()}`:"";return this.restRequest("GET",`/v1/tools${n}`)}async listAllTools(e={}){return(0,Go.listAllPages)((r,n)=>this.listTools({...e,page:r,limit:n}))}async createTool(e,r){return this.restRequest("POST","/v1/tools",{...r,id:e})}async updateTool(e,r){return this.restRequest("PUT",`/v1/tools/${encodeURIComponent(e)}`,r)}async deleteTool(e){try{return await this.restRequest("DELETE",`/v1/tools/${encodeURIComponent(e)}`),!0}catch(r){if(r.message?.includes("404"))return!1;throw r}}async renameTool(e,r){return this.restRequest("POST",`/v1/tools/${encodeURIComponent(e)}/rename`,{newId:r})}async getWorkflow(e){return this.getTool(e)}async archiveWorkflow(e,r=!0){return this.upsertWorkflow(e,{archived:r})}async createWorkflow(e,r){return this.createTool(e,r)}async updateWorkflow(e,r){return this.updateTool(e,r)}async upsertWorkflow(e,r){return await this.getTool(e)?this.updateTool(e,r):this.createTool(e,r)}async deleteWorkflow(e){return this.deleteTool(e)}async renameWorkflow(e,r){return this.renameTool(e,r)}async listSchedules(e={}){let r=(0,Go.createListQueryParams)(e),n=r.size>0?`?${r.toString()}`:"",i=e.toolId?`/v1/tools/${encodeURIComponent(e.toolId)}/schedules${n}`:`/v1/schedules${n}`,o=await this.restRequest("GET",i);return{...o,data:o.data.map(s=>this.mapOpenAPIScheduleToToolSchedule(s))}}async listAllSchedules(e={}){return(0,Go.listAllPages)((r,n)=>this.listSchedules({...e,page:r,limit:n}))}async getToolSchedule(e,r){try{let n=await this.restRequest("GET",`/v1/tools/${encodeURIComponent(e)}/schedules/${encodeURIComponent(r)}`);return this.mapOpenAPIScheduleToToolSchedule(n)}catch(n){if(n.message?.includes("404")||n.message?.includes("not found"))return null;throw n}}async createToolSchedule(e,r){let n=await this.restRequest("POST",`/v1/tools/${encodeURIComponent(e)}/schedules`,{...r,timezone:r.timezone||(0,bTe.getRuntimeTimezone)()});return this.mapOpenAPIScheduleToToolSchedule(n)}async updateToolSchedule(e,r,n){let i=await this.restRequest("PUT",`/v1/tools/${encodeURIComponent(e)}/schedules/${encodeURIComponent(r)}`,n);return this.mapOpenAPIScheduleToToolSchedule(i)}async deleteToolSchedule(e,r){return await this.restRequest("DELETE",`/v1/tools/${encodeURIComponent(e)}/schedules/${encodeURIComponent(r)}`),!0}async bulkSetSchedulesEnabled(e,r){return this.restRequest("POST","/v1/schedules/bulk/enable",{ids:e,enabled:r})}async bulkDeleteSchedules(e){return this.restRequest("POST","/v1/schedules/bulk/delete",{ids:e})}async listCredentials(e={}){let r=(0,Go.createListQueryParams)(e);e.systemId!==void 0&&r.set("systemId",e.systemId);let n=r.size>0?`?${r.toString()}`:"";return this.restRequest("GET",`/v1/credentials${n}`)}async listAllCredentials(e={}){return(0,Go.listAllPages)((r,n)=>this.listCredentials({...e,page:r,limit:n}))}async createCredentials(e){return(await this.restRequest("POST","/v1/credentials",e)).data}async replaceCredentials(e,r){return(await this.restRequest("PUT",`/v1/credentials/${encodeURIComponent(e)}`,{credentials:r})).data}async updateCredentials(e,r){return(await this.restRequest("PATCH",`/v1/credentials/${encodeURIComponent(e)}`,r)).data}async deleteCredentials(e){await this.restRequest("DELETE",`/v1/credentials/${encodeURIComponent(e)}`)}async setDefaultCredentials(e){await this.restRequest("POST",`/v1/credentials/${encodeURIComponent(e)}/default`)}async listSystems(e={}){let r=(0,Go.createListQueryParams)(e),n=r.size>0?`?${r.toString()}`:"";return this.restRequest("GET",`/v1/systems${n}`)}async listAllSystems(e={}){return(0,Go.listAllPages)((r,n)=>this.listSystems({...e,page:r,limit:n}))}async getSystem(e){return(await this.restRequest("GET",`/v1/systems/${encodeURIComponent(e)}`)).data}async createSystem(e){return(await this.restRequest("POST","/v1/systems",e)).data}async updateSystem(e,r){return(await this.restRequest("PATCH",`/v1/systems/${encodeURIComponent(e)}`,r)).data}async deleteSystem(e){return await this.restRequest("DELETE",`/v1/systems/${encodeURIComponent(e)}`),!0}async bulkDeleteSystems(e){return this.restRequest("POST","/v1/systems/bulk/delete",{ids:e})}async createOAuthExchange(e){return(await this.restRequest("POST","/v1/oauth/exchanges",e)).data}async completeOAuthExchange(e,r){return(await this.restRequest("POST",`/v1/oauth/exchanges/${encodeURIComponent(e)}/complete`,r)).data}async searchSystemDocumentation(e,r){return(await this.restRequest("POST",`/v1/systems/${encodeURIComponent(e)}/documentation/search`,{keywords:r})).data}async triggerSystemDocumentationScrapeJob(e,r){return(await this.restRequest("POST",`/v1/systems/${encodeURIComponent(e)}/documentation/scrape`,r)).data}async fetchOpenApiSpec(e,r,n){return(await this.restRequest("POST",`/v1/systems/${encodeURIComponent(e)}/documentation/openapi`,{url:r,link:n?.link})).data}async uploadSystemDocumentationFiles(e,r,n){let i=await this.uploadFiles(r,{process:!0}),o=i.flatMap(s=>s.status==="uploaded"?[s.id]:[]);if(o.length>0)try{await this.restRequest("POST",`/v1/systems/${encodeURIComponent(e)}/documentation/files`,{fileIds:o,link:n?.link!==!1})}catch(s){throw await Promise.all(o.map(a=>this.deleteFileUpload(a).catch(()=>{}))),s}if(!n?.settle){let s=i.filter(a=>a.status==="failed");if(s.length>0)throw new Error(s.map(a=>a.error).join("; "))}return i}async listSystemDocumentationFiles(e,r){let n=new URLSearchParams;r?.length&&n.set("fileIds",r.join(","));let i=n.size>0?`?${n.toString()}`:"";return(await this.restRequest("GET",`/v1/systems/${encodeURIComponent(e)}/documentation/files${i}`)).data}async getSystemDocumentationFileContent(e,r,n){return(await this.restRequest("GET",`/v1/systems/${encodeURIComponent(e)}/documentation/files/${encodeURIComponent(r)}/content?processed=${n.processed}`)).data}async deleteSystemDocumentationFile(e,r){await this.restRequest("DELETE",`/v1/systems/${encodeURIComponent(e)}/documentation/files/${encodeURIComponent(r)}`)}async generateCredentialsLink(e){try{return{success:!0,credentialsUrl:(await this.restRequest("POST","/v1/authenticate",e||{})).data.credentialsUrl}}catch(r){return{success:!1,error:r.message}}}};zu.SuperglueClient=gv});var Gz=g(it=>{"use strict";Object.defineProperty(it,"__esModule",{value:!0});it.UnquotedKeyStrategy=it.TripleQuoteStrategy=it.TrailingCommaStrategy=it.SingleQuoteStrategy=it.PythonLiteralStrategy=it.CommentStrategy=it.ResilientJsonParser=it.RepairStrategy=void 0;it.parseJsonResilient=STe;it.parseJSON=BTe;it.isValidJson=wTe;it.prettyPrintJson=QTe;it.minifyJson=vTe;var $n=class{validate(e){try{return JSON.parse(e),!0}catch{return!1}}};it.RepairStrategy=$n;var py=class extends $n{constructor(){super(...arguments),this.name="TripleQuoteRepair",this.description="Converts triple-quoted strings to proper JSON, parsing nested JSON content"}canApply(e){return/"""/.test(e)}apply(e){return e.replace(/"""([\s\S]*?)"""/g,(r,n)=>{let i=n.trim();if(i.startsWith("{")&&i.endsWith("}")||i.startsWith("[")&&i.endsWith("]"))try{let s=JSON.parse(i);return JSON.stringify(s)}catch{return`"${n.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\t/g,"\\t")}"`}return`"${n.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\t/g,"\\t")}"`})}};it.TripleQuoteStrategy=py;var fy=class extends $n{constructor(){super(...arguments),this.name="PythonLiteralRepair",this.description="Converts Python literals to JavaScript equivalents"}canApply(e){return/\b(None|True|False)\b/.test(e)}apply(e){return e.replace(/\bNone\b/g,"null").replace(/\bTrue\b/g,"true").replace(/\bFalse\b/g,"false")}};it.PythonLiteralStrategy=fy;var hy=class extends $n{constructor(){super(...arguments),this.name="TrailingCommaRepair",this.description="Removes trailing commas from objects and arrays"}canApply(e){return/,\s*[}\]]/.test(e)}apply(e){return e.replace(/,(\s*[}\]])/g,"$1")}};it.TrailingCommaStrategy=hy;var gy=class extends $n{constructor(){super(...arguments),this.name="SingleQuoteRepair",this.description="Converts single quotes to double quotes"}canApply(e){return/[{,]\s*'[^']*'\s*:/.test(e)||/:\s*'[^']*'/.test(e)}apply(e){let r=e.replace(/([{,]\s*)'([^']+)'(\s*:)/g,'$1"$2"$3');return r=r.replace(/(:\s*)'([^']+)'(\s*[,}])/g,'$1"$2"$3'),r}};it.SingleQuoteStrategy=gy;var my=class extends $n{constructor(){super(...arguments),this.name="UnquotedKeyRepair",this.description="Adds quotes to unquoted object keys"}canApply(e){return/[{,]\s*[a-zA-Z_$][a-zA-Z0-9_$]*\s*:/.test(e)}apply(e){return e.replace(/([{,]\s*)([a-zA-Z_$][a-zA-Z0-9_$]*)(\s*:)/g,'$1"$2"$3')}};it.UnquotedKeyStrategy=my;var yy=class extends $n{constructor(){super(...arguments),this.name="CommentRemoval",this.description="Removes JavaScript-style comments"}canApply(e){return/\/\/.*$|\/\*[\s\S]*?\*\//m.test(e)}apply(e){let r=e.replace(/\/\/.*$/gm,"");return r=r.replace(/\/\*[\s\S]*?\*\//g,""),r}};it.CommentStrategy=yy;var mv=class extends $n{constructor(){super(...arguments),this.name="UnescapedControlCharactersRepair",this.description="Escapes unescaped control characters (newlines, tabs, etc.) in JSON strings"}canApply(e){try{return JSON.parse(e),!1}catch(r){let n=r.message||"";return n.includes("control character")||n.includes("Bad control")||n.includes("Unexpected token")&&/[\n\r\t]/.test(e)}}apply(e){let r="",n=!1,i=!1;for(let o=0;o<e.length;o++){let s=e[o],a=o>0?e[o-1]:"";if(i){r+=s,i=!1;continue}if(s==="\\"&&n){r+=s,i=!0;continue}if(s==='"'&&a!=="\\"){n=!n,r+=s;continue}if(n)switch(s){case`
|
|
1746
1746
|
`:r+="\\n";break;case"\r":r+="\\r";break;case" ":r+="\\t";break;case"\b":r+="\\b";break;case"\f":r+="\\f";break;default:let c=s.charCodeAt(0);c<32?r+="\\u"+("0000"+c.toString(16)).slice(-4):r+=s}else r+=s}return r}},yv=class extends $n{constructor(){super(...arguments),this.name="TrailingCharactersRepair",this.description="Removes trailing characters after valid JSON structure"}canApply(e){let r=e.trim();if(!r.startsWith("{")&&!r.startsWith("["))return!1;let n=0,i=0,o=!1,s=!1;for(let a=0;a<r.length;a++){let c=r[a];if(o)s?s=!1:c==="\\"?s=!0:c==='"'&&(o=!1);else if(c==='"')o=!0;else if(c==="{")n++;else if(c==="}"){if(n--,n===0&&i===0&&a>0&&a<r.length-1)return!0}else if(c==="[")i++;else if(c==="]"&&(i--,i===0&&n===0&&a>0&&a<r.length-1))return!0}return!1}apply(e){let r=e.trim(),n=0,i=0,o=!1,s=!1,a=-1;for(let c=0;c<r.length;c++){let u=r[c];if(o)s?s=!1:u==="\\"?s=!0:u==='"'&&(o=!1);else if(u==='"')o=!0;else if(u==="{")n++;else if(u==="}"){if(n--,n===0&&i===0&&c>0){a=c;break}}else if(u==="[")i++;else if(u==="]"&&(i--,i===0&&n===0&&c>0)){a=c;break}}return a>0&&a<r.length-1?r.substring(0,a+1):e}},Gu=class{constructor(e={}){this.strategies=[],this.repairLog=[],this.options={attemptRepair:!0,maxDepth:10,preserveStringsOnFailure:!1,logRepairs:!1,...e},this.initializeDefaultStrategies(),e.customStrategies&&this.strategies.push(...e.customStrategies)}initializeDefaultStrategies(){this.strategies=[new py,new gy,new mv,new yv,new fy,new hy,new my,new yy]}parse(e){let r=Date.now();this.repairLog=[];let n=e instanceof Buffer?e.toString("utf8"):String(e);try{return{success:!0,data:JSON.parse(n),metadata:{parseTime:Date.now()-r,strategiesApplied:[]}}}catch(s){if(!this.options.attemptRepair)return{success:!1,error:`JSON parse error: ${s}`,metadata:{parseTime:Date.now()-r}}}let i=n,o=[];for(let s of this.strategies)if(s.canApply(i)){let a=i;if(i=s.apply(i),a!==i){o.push(s.name),this.repairLog.push(s.description),this.options.logRepairs&&console.log(`Applied ${s.name}: ${s.description}`);try{return{success:!0,data:JSON.parse(i),repairs:this.repairLog,metadata:{parseTime:Date.now()-r,strategiesApplied:o}}}catch{}}}try{return{success:!0,data:JSON.parse(i),repairs:this.repairLog,metadata:{parseTime:Date.now()-r,strategiesApplied:o}}}catch(s){let a=this.aggressiveFallback(i);return a.success?{...a,repairs:[...this.repairLog,"Applied aggressive fallback"],metadata:{parseTime:Date.now()-r,strategiesApplied:[...o,"AggressiveFallback"]}}:{success:!1,error:`Failed to parse JSON after applying ${o.length} strategies: ${s}`,repairs:this.repairLog,metadata:{parseTime:Date.now()-r,strategiesApplied:o}}}}aggressiveFallback(e){try{let r=e.indexOf("{"),n=e.indexOf("[");if(r===-1&&n===-1)return{success:!1,error:"No JSON-like structure found"};let i=r===-1?n:n===-1?r:Math.min(r,n),o=e.substring(i);for(let a of this.strategies)a.canApply(o)&&(o=a.apply(o));return{success:!0,data:JSON.parse(o)}}catch(r){return{success:!1,error:`Aggressive fallback failed: ${r}`}}}addStrategy(e){this.strategies.push(e)}removeStrategy(e){this.strategies=this.strategies.filter(r=>r.name!==e)}getStrategies(){return this.strategies.map(e=>e.name)}};it.ResilientJsonParser=Gu;var zz=new Gu;function STe(t,e){return(e?new Gu(e):zz).parse(t)}function BTe(t){let e=zz.parse(t);if(e.success)return e.repairs&&e.repairs.length>0&&console.log("JSON parsed with repairs:",e.repairs),e.data;throw new Error(`Failed to parse JSON: ${e.error}`)}function wTe(t){try{return JSON.parse(t),!0}catch{return!1}}function QTe(t,e=2){return JSON.stringify(t,null,e)}function vTe(t){let r=new Gu().parse(t);if(r.success)return JSON.stringify(r.data);throw new Error("Cannot minify invalid JSON")}});var Gr=g(K=>{"use strict";var _Te=K&&K.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Ae=K&&K.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&_Te(e,t,r)};Object.defineProperty(K,"__esModule",{value:!0});K.SSELogSubscriptionManager=K.SuperglueHttpError=K.SuperglueClient=void 0;Ae(AN(),K);Ae(RU(),K);Ae(qU(),K);Ae(zU(),K);Ae(WU(),K);Ae(ZU(),K);Ae(XU(),K);Ae(hd(),K);Ae(kM(),K);Ae(OM(),K);Ae(UM(),K);Ae(MM(),K);Ae(tb(),K);Ae(LM(),K);Ae($M(),K);Ae(jM(),K);Ae(qM(),K);Ae(nb(),K);Ae(zM(),K);Ae(YM(),K);Ae(VM(),K);Ae(WM(),K);Ae(tp(),K);Ae(KM(),K);Ae(XM(),K);Ae(tx(),K);Ae(rx(),K);Ae(ox(),K);Ae(sx(),K);Ae(Ax(),K);Ae(fx(),K);Ae(gx(),K);Ae(FC(),K);Ae(Qx(),K);Ae(_x(),K);Ae(xh(),K);Ae(jx(),K);Ae(vb(),K);Ae(Gx(),K);Ae(Wx(),K);Ae(Kx(),K);Ae(Br(),K);Ae(Vn(),K);Ae(Xx(),K);Ae(eL(),K);Ae(Kh(),K);Ae(kc(),K);Ae(Gl(),K);var Yz=Hz();Object.defineProperty(K,"SuperglueClient",{enumerable:!0,get:function(){return Yz.SuperglueClient}});Object.defineProperty(K,"SuperglueHttpError",{enumerable:!0,get:function(){return Yz.SuperglueHttpError}});var DTe=Tb();Object.defineProperty(K,"SSELogSubscriptionManager",{enumerable:!0,get:function(){return DTe.SSELogSubscriptionManager}});Ae(Gz(),K)});var Xy=require("commander");var br=ge(require("fs")),Wz=ge(require("os")),Vo=ge(require("path")),LA=ge(Gr()),Vz=new Set(["runner","builder","admin"]),Jz={output:{mode:"stdout",directory:".superglue/output"},preset:"admin"};function Jo(t){let e=Vo.join(process.cwd(),".superglue"),r=Wz.homedir();if(!r)return e;let n=Vo.join(r,".superglue");return t===!0?e:t===!1?n:br.existsSync(Vo.join(e,"config.json"))?e:n}function Ev(t){return Vo.join(Jo(t),"config.json")}function Ey(t){let e=Ev(t);if(!br.existsSync(e))return{};try{return JSON.parse(br.readFileSync(e,"utf-8"))}catch{return{}}}function Yu(t){let e=Ey(),r=t.apiKey||(0,LA.readProcessEnvironmentValue)("SUPERGLUE_API_KEY")||e.apiKey||"",n=t.endpoint||(0,LA.readProcessEnvironmentValue)("SUPERGLUE_API_ENDPOINT")||e.endpoint||"https://api.superglue.cloud",i=(0,LA.readProcessEnvironmentValue)("SUPERGLUE_WEB_ENDPOINT")||e.webEndpoint||n.replace(/:3002\b/,":3001").replace(/api\.superglue/,"app.superglue"),o=(0,LA.readProcessEnvironmentValue)("SUPERGLUE_CLI_PRESET"),s=o&&Vz.has(o)?o:e.preset&&Vz.has(e.preset)?e.preset:"admin";return{...Jz,...e,apiKey:r,endpoint:n,webEndpoint:i,preset:s,output:{...Jz.output,...e.output}}}function Iy(t,e){let r=Jo(e);br.existsSync(r)||br.mkdirSync(r,{recursive:!0}),br.writeFileSync(Vo.join(r,"config.json"),JSON.stringify(t,null,2)+`
|
|
1747
|
-
`,{mode:384})}function Cy(t,e){let r=Vo.join(Jo(e),"drafts");if(br.existsSync(r)||br.mkdirSync(r,{recursive:!0}),t.output.mode==="stdout+file"){let n=Vo.resolve(t.output.directory);br.existsSync(n)||br.mkdirSync(n,{recursive:!0})}}var Qv=ge(Gr());var Iv=ge(require("readline"));var Xz=require("child_process"),eG=require("util");var Zz={name:"@superglue/cli",version:"1.1.
|
|
1747
|
+
`,{mode:384})}function Cy(t,e){let r=Vo.join(Jo(e),"drafts");if(br.existsSync(r)||br.mkdirSync(r,{recursive:!0}),t.output.mode==="stdout+file"){let n=Vo.resolve(t.output.directory);br.existsSync(n)||br.mkdirSync(n,{recursive:!0})}}var Qv=ge(Gr());var Iv=ge(require("readline"));var Xz=require("child_process"),eG=require("util");var Zz={name:"@superglue/cli",version:"1.1.154",bin:{sg:"./dist/cli.js"},files:[".claude-plugin/","dist/","skills/","LICENSE"],dependencies:{commander:"15.0.0-0","fast-json-patch":"3.1.1"},devDependencies:{"@superglue/shared":"file:../shared","@types/node":"25.5.0",tsup:"8.5.1",typescript:"5.8.3"},scripts:{build:"tsup && (cp -r skills dist/ 2>/dev/null || true)",dev:"tsup --watch","type-check":"tsc --noEmit",prepublishOnly:"npm run build"},publishConfig:{access:"public"}};var RTe=(0,eG.promisify)(Xz.exec),sr=Zz.version;function Kz(t){let e=t.match(/^(\d+)(?:-(.+))?$/);return e?{numeric:parseInt(e[1],10),prerelease:e[2]||null}:{numeric:0,prerelease:t}}function Sy(t,e){let r=t.split("."),n=e.split("."),i=Math.max(r.length,n.length);for(let o=0;o<i;o++){let s=Kz(r[o]||"0"),a=Kz(n[o]||"0");if(s.numeric<a.numeric)return-1;if(s.numeric>a.numeric||s.prerelease===null&&a.prerelease!==null)return 1;if(s.prerelease!==null&&a.prerelease===null)return-1;if(s.prerelease!==null&&a.prerelease!==null){if(s.prerelease<a.prerelease)return-1;if(s.prerelease>a.prerelease)return 1}}return 0}async function By(){try{let t=await fetch("https://registry.npmjs.org/@superglue/cli/latest",{signal:AbortSignal.timeout(5e3)});return t.ok&&(await t.json()).version||null}catch{return null}}var by=null;function tG(){le()&&(by=By())}async function rG(){if(!(!le()||!by)){try{let t=new Promise(r=>{setTimeout(()=>r(null),2e3).unref()}),e=await Promise.race([by,t]);e&&Sy(sr,e)<0&&(console.error(""),console.error(`${m.cyan}${m.bold} Update available: ${sr} \u2192 ${e}${m.reset}`),console.error(`${m.cyan} Run ${m.bold}sg update${m.reset}${m.cyan} to upgrade${m.reset}`),console.error(""))}catch{}by=null}}async function nG(){let t=await By();if(!t)return{success:!1,message:"Could not fetch latest version from npm"};if(Sy(sr,t)>=0)return{success:!0,message:`Already on latest version (${sr})`};try{return await RTe("npm install -g @superglue/cli@latest"),{success:!0,message:`Updated from ${sr} to ${t}`}}catch(e){return{success:!1,message:`Update failed: ${e.message}. Try manually: npm install -g @superglue/cli@latest`}}}var le=()=>process.argv.includes("--table")&&process.stdout.isTTY,bn=()=>process.argv.includes("--full"),m={reset:"\x1B[0m",bold:"\x1B[1m",dim:"\x1B[2m",italic:"\x1B[3m",underline:"\x1B[4m",red:"\x1B[31m",green:"\x1B[32m",yellow:"\x1B[33m",blue:"\x1B[34m",magenta:"\x1B[35m",cyan:"\x1B[36m",white:"\x1B[37m",gray:"\x1B[90m",bgRed:"\x1B[41m",bgGreen:"\x1B[42m",bgYellow:"\x1B[43m",bgBlue:"\x1B[44m",bgMagenta:"\x1B[45m",bgCyan:"\x1B[46m"};function iG(t,e){let r=e||t;return`\x1B]8;;${t}\x07${m.underline}${m.cyan}${r}${m.reset}\x1B]8;;\x07`}function oG(){if(!le())return;let t=m.reset,e=m.dim,r="\x1B[47;30m",n=[" #@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@- "," =@@@- @@@@ "," @@@ @@% "," -@@ @@@@= @@@ @@@ @@@@@#@ @@@@@@@ @@@@@@@ @@@@@@ @@@ @@@ @@@ @@@@@@* %@@ "," @@ @@@ *@ @@@ @@@ @@@ :@@ @@@ @@@ -@@ @@@ @% @@@ @@@ @@@ @@* @@# "," #@@ @@@# @@@ @@@ @@@ :@@ @@@ @@@ -@@ @@@ @@@ @@@ @@@ @@* @@ "," @@- @@@@= @@@ @@@ @@@@@@@ @@@@@@ @@@@@@@ @@@ @@% @@@ @@@ @@@ @@@@@. @@."," #@% .@@@@ @@@ @@@ @@@ @@@ @@@ -@@ @@@ @@% @@@ @@@ @@@ @@* @@ "," @@ @ @@@ @@@ @@@ @@@ @@@ @@@ -@@ @@@ @@% @@@ @@@ @@@ @@* *@@ "," -@@ @@@@= @@@@@@ @@@ @@@@@@@ @@@ -@@ @@@@@@ @@@@@@% @@@@@@. @@@@@@* #@@ "," :@@* @@@ "," %@@@ =@@@. "," :@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@% "];console.log(""),n.forEach(i=>{let o=i.search(/\S/),s=i.length-[...i].reverse().join("").search(/\S/)-1;if(o===-1)return console.log(" "+i);let a=i.slice(0,o),c=i.slice(o,s+1).split("").map(l=>l===" "?" ":"\u2588").join(""),u=i.slice(s+1);console.log(` ${a}${r}${c}${t}${u}`)}),console.log(` ${e} CLI v${sr}${t}`),console.log("")}function tt(t){if(!le())return{stop:()=>{},update:()=>{},log:()=>{}};let e=["\u280B","\u2819","\u2839","\u2838","\u283C","\u2834","\u2826","\u2827","\u2807","\u280F"],r=0,n=t,i=()=>process.stdout.write("\r\x1B[2K"),o=()=>{process.stdout.write(`\r ${m.cyan}${e[r++%e.length]}${m.reset} ${n}`)},s=setInterval(o,80);return{update:a=>{n=a},log:a=>{i(),console.log(` ${m.dim}\u2502${m.reset} ${a}`),o()},stop:a=>{clearInterval(s),i(),a&&console.log(` ${a}`)}}}function ie(t){le()?wy(t):console.log(JSON.stringify(t,null,2))}function Qe(t,e){le()?(console.log(` ${m.green}\u2713${m.reset} ${t}`),e&&wy(e,4)):console.log(JSON.stringify({success:!0,message:t,...e&&typeof e=="object"?e:{data:e}}))}function _(t,e){le()?(console.error(` ${m.red}\u2717${m.reset} ${t}`),e&&wy(e,4)):console.error(JSON.stringify({success:!1,error:t,details:e}))}function sG(t){le()&&console.log(` ${m.yellow}\u26A0${m.reset} ${t}`)}function Wt(t){le()&&console.log(` ${m.dim}${t}${m.reset}`)}function Wo(t){le()&&(console.log(`
|
|
1748
1748
|
${m.bold}${m.cyan}${t}${m.reset}`),console.log(` ${m.dim}${"\u2500".repeat(t.length)}${m.reset}`))}function lo(t,e,r){if(!le()){console.log(JSON.stringify({success:!0,total:r?.total??t.length,items:t}));return}if(t.length===0){console.log(`
|
|
1749
1749
|
${m.dim}0 results${m.reset}
|
|
1750
1750
|
`);return}let n=e||Object.keys(t[0]),i=bn()?1/0:60,o=n.map(l=>Math.min(i,Math.max(l.length,...t.map(d=>String(d[l]??"").replace(/[\n\r]+/g," ").trim().length))));console.log("");let s=n.map((l,d)=>`${m.bold}${m.cyan}${l.toUpperCase().padEnd(o[d])}${m.reset}`).join(" ");console.log(` ${s}`);let a=o.map(l=>`${m.dim}${"\u2500".repeat(l)}${m.reset}`).join(`${m.dim}\u2500\u2500${m.reset}`);console.log(` ${a}`);for(let l of t){let d=n.map((A,p)=>{let h=String(l[A]??"").replace(/[\n\r]+/g," ").trim();if(h.length>i){let b=`\u2026 (${h.length})`;h=h.slice(0,Math.max(0,i-b.length))+`${m.dim}${b}${m.reset}`}return A==="status"?`${{success:m.green,running:m.yellow,failed:m.red,aborted:m.red,error:m.red,pending:m.dim}[h.toLowerCase()]||""}${h.padEnd(o[p])}${m.reset}`:h.padEnd(o[p])}).join(" ");console.log(` ${d}`)}let c=r?.total??t.length,u=c===t.length?`${t.length} result${t.length===1?"":"s"}`:`${t.length} of ${c} result${c===1?"":"s"}`;console.log(`
|