@botpress/client 2.0.0 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1,7 +1,7 @@
1
- var pk=Object.create;var Et=Object.defineProperty;var uk=Object.getOwnPropertyDescriptor;var ck=Object.getOwnPropertyNames;var dk=Object.getPrototypeOf,lk=Object.prototype.hasOwnProperty;var h=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),te=(e,t)=>{for(var s in t)Et(e,s,{get:t[s],enumerable:!0})},gk=(e,t,s,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of ck(t))!lk.call(e,a)&&a!==s&&Et(e,a,{get:()=>t[a],enumerable:!(n=uk(t,a))||n.enumerable});return e};var Te=(e,t,s)=>(s=e!=null?pk(dk(e)):{},gk(t||!e||!e.__esModule?Et(s,"default",{value:e,enumerable:!0}):s,e));var ot=h((UC,Ba)=>{"use strict";Ba.exports=Object});var Sr=h((GC,Ta)=>{"use strict";Ta.exports=Error});var Er=h((SC,wa)=>{"use strict";wa.exports=EvalError});var Lr=h((EC,Ua)=>{"use strict";Ua.exports=RangeError});var Wr=h((LC,Ga)=>{"use strict";Ga.exports=ReferenceError});var it=h((WC,Sa)=>{"use strict";Sa.exports=SyntaxError});var qe=h((_C,Ea)=>{"use strict";Ea.exports=TypeError});var _r=h((HC,La)=>{"use strict";La.exports=URIError});var Hr=h((QC,Wa)=>{"use strict";Wa.exports=Math.abs});var Qr=h((DC,_a)=>{"use strict";_a.exports=Math.floor});var Dr=h((FC,Ha)=>{"use strict";Ha.exports=Math.max});var Fr=h((MC,Qa)=>{"use strict";Qa.exports=Math.min});var Mr=h((OC,Da)=>{"use strict";Da.exports=Math.pow});var Or=h((VC,Fa)=>{"use strict";Fa.exports=Math.round});var Oa=h((NC,Ma)=>{"use strict";Ma.exports=Number.isNaN||function(t){return t!==t}});var Vr=h((KC,Va)=>{"use strict";var Yk=Oa();Va.exports=function(t){return Yk(t)||t===0?t:t<0?-1:1}});var Ka=h(($C,Na)=>{"use strict";Na.exports=Object.getOwnPropertyDescriptor});var Ue=h((zC,$a)=>{"use strict";var pt=Ka();if(pt)try{pt([],"length")}catch{pt=null}$a.exports=pt});var Ge=h((JC,za)=>{"use strict";var ut=Object.defineProperty||!1;if(ut)try{ut({},"a",{value:1})}catch{ut=!1}za.exports=ut});var ja=h((jC,Ja)=>{"use strict";Ja.exports=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var t={},s=Symbol("test"),n=Object(s);if(typeof s=="string"||Object.prototype.toString.call(s)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var a=42;t[s]=a;for(var o in t)return!1;if(typeof Object.keys=="function"&&Object.keys(t).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(t).length!==0)return!1;var i=Object.getOwnPropertySymbols(t);if(i.length!==1||i[0]!==s||!Object.prototype.propertyIsEnumerable.call(t,s))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var p=Object.getOwnPropertyDescriptor(t,s);if(p.value!==a||p.enumerable!==!0)return!1}return!0}});var Nr=h((YC,Za)=>{"use strict";var Ya=typeof Symbol<"u"&&Symbol,Zk=ja();Za.exports=function(){return typeof Ya!="function"||typeof Symbol!="function"||typeof Ya("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:Zk()}});var ct=h((ZC,Xa)=>{"use strict";Xa.exports=typeof Reflect<"u"&&Reflect.getPrototypeOf||null});var dt=h((XC,eo)=>{"use strict";var Xk=ot();eo.exports=Xk.getPrototypeOf||null});var so=h((eB,ro)=>{"use strict";var eP="Function.prototype.bind called on incompatible ",tP=Object.prototype.toString,rP=Math.max,sP="[object Function]",to=function(t,s){for(var n=[],a=0;a<t.length;a+=1)n[a]=t[a];for(var o=0;o<s.length;o+=1)n[o+t.length]=s[o];return n},nP=function(t,s){for(var n=[],a=s||0,o=0;a<t.length;a+=1,o+=1)n[o]=t[a];return n},aP=function(e,t){for(var s="",n=0;n<e.length;n+=1)s+=e[n],n+1<e.length&&(s+=t);return s};ro.exports=function(t){var s=this;if(typeof s!="function"||tP.apply(s)!==sP)throw new TypeError(eP+s);for(var n=nP(arguments,1),a,o=function(){if(this instanceof a){var y=s.apply(this,to(n,arguments));return Object(y)===y?y:this}return s.apply(t,to(n,arguments))},i=rP(0,s.length-n.length),p=[],u=0;u<i;u++)p[u]="$"+u;if(a=Function("binder","return function ("+aP(p,",")+"){ return binder.apply(this,arguments); }")(o),s.prototype){var r=function(){};r.prototype=s.prototype,a.prototype=new r,r.prototype=null}return a}});var he=h((tB,no)=>{"use strict";var oP=so();no.exports=Function.prototype.bind||oP});var ze=h((rB,ao)=>{"use strict";ao.exports=Function.prototype.call});var lt=h((sB,oo)=>{"use strict";oo.exports=Function.prototype.apply});var po=h((nB,io)=>{"use strict";io.exports=typeof Reflect<"u"&&Reflect&&Reflect.apply});var co=h((aB,uo)=>{"use strict";var iP=he(),pP=lt(),uP=ze(),cP=po();uo.exports=cP||iP.call(uP,pP)});var go=h((oB,lo)=>{"use strict";var dP=he(),lP=qe(),gP=ze(),yP=co();lo.exports=function(t){if(t.length<1||typeof t[0]!="function")throw new lP("a function is required");return yP(dP,gP,t)}});var bo=h((iB,ho)=>{"use strict";var mP=go(),yo=Ue(),Ro;try{Ro=[].__proto__===Array.prototype}catch(e){if(!e||typeof e!="object"||!("code"in e)||e.code!=="ERR_PROTO_ACCESS")throw e}var Kr=!!Ro&&yo&&yo(Object.prototype,"__proto__"),qo=Object,mo=qo.getPrototypeOf;ho.exports=Kr&&typeof Kr.get=="function"?mP([Kr.get]):typeof mo=="function"?function(t){return mo(t==null?t:qo(t))}:!1});var $r=h((pB,ko)=>{"use strict";var fo=ct(),Io=dt(),xo=bo();ko.exports=fo?function(t){return fo(t)}:Io?function(t){if(!t||typeof t!="object"&&typeof t!="function")throw new TypeError("getProto: not an object");return Io(t)}:xo?function(t){return xo(t)}:null});var zr=h((uB,Po)=>{"use strict";var RP=Function.prototype.call,qP=Object.prototype.hasOwnProperty,hP=he();Po.exports=hP.call(RP,qP)});var Uo=h((cB,wo)=>{"use strict";var A,bP=ot(),fP=Sr(),IP=Er(),xP=Lr(),kP=Wr(),We=it(),Le=qe(),PP=_r(),vP=Hr(),AP=Qr(),CP=Dr(),BP=Fr(),TP=Mr(),wP=Or(),UP=Vr(),Bo=Function,Jr=function(e){try{return Bo('"use strict"; return ('+e+").constructor;")()}catch{}},Je=Ue(),GP=Ge(),jr=function(){throw new Le},SP=Je?(function(){try{return arguments.callee,jr}catch{try{return Je(arguments,"callee").get}catch{return jr}}})():jr,Se=Nr()(),_=$r(),EP=dt(),LP=ct(),To=lt(),je=ze(),Ee={},WP=typeof Uint8Array>"u"||!_?A:_(Uint8Array),be={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?A:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?A:ArrayBuffer,"%ArrayIteratorPrototype%":Se&&_?_([][Symbol.iterator]()):A,"%AsyncFromSyncIteratorPrototype%":A,"%AsyncFunction%":Ee,"%AsyncGenerator%":Ee,"%AsyncGeneratorFunction%":Ee,"%AsyncIteratorPrototype%":Ee,"%Atomics%":typeof Atomics>"u"?A:Atomics,"%BigInt%":typeof BigInt>"u"?A:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?A:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?A:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?A:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":fP,"%eval%":eval,"%EvalError%":IP,"%Float32Array%":typeof Float32Array>"u"?A:Float32Array,"%Float64Array%":typeof Float64Array>"u"?A:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?A:FinalizationRegistry,"%Function%":Bo,"%GeneratorFunction%":Ee,"%Int8Array%":typeof Int8Array>"u"?A:Int8Array,"%Int16Array%":typeof Int16Array>"u"?A:Int16Array,"%Int32Array%":typeof Int32Array>"u"?A:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":Se&&_?_(_([][Symbol.iterator]())):A,"%JSON%":typeof JSON=="object"?JSON:A,"%Map%":typeof Map>"u"?A:Map,"%MapIteratorPrototype%":typeof Map>"u"||!Se||!_?A:_(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":bP,"%Object.getOwnPropertyDescriptor%":Je,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?A:Promise,"%Proxy%":typeof Proxy>"u"?A:Proxy,"%RangeError%":xP,"%ReferenceError%":kP,"%Reflect%":typeof Reflect>"u"?A:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?A:Set,"%SetIteratorPrototype%":typeof Set>"u"||!Se||!_?A:_(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?A:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":Se&&_?_(""[Symbol.iterator]()):A,"%Symbol%":Se?Symbol:A,"%SyntaxError%":We,"%ThrowTypeError%":SP,"%TypedArray%":WP,"%TypeError%":Le,"%Uint8Array%":typeof Uint8Array>"u"?A:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?A:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?A:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?A:Uint32Array,"%URIError%":PP,"%WeakMap%":typeof WeakMap>"u"?A:WeakMap,"%WeakRef%":typeof WeakRef>"u"?A:WeakRef,"%WeakSet%":typeof WeakSet>"u"?A:WeakSet,"%Function.prototype.call%":je,"%Function.prototype.apply%":To,"%Object.defineProperty%":GP,"%Object.getPrototypeOf%":EP,"%Math.abs%":vP,"%Math.floor%":AP,"%Math.max%":CP,"%Math.min%":BP,"%Math.pow%":TP,"%Math.round%":wP,"%Math.sign%":UP,"%Reflect.getPrototypeOf%":LP};if(_)try{null.error}catch(e){vo=_(_(e)),be["%Error.prototype%"]=vo}var vo,_P=function e(t){var s;if(t==="%AsyncFunction%")s=Jr("async function () {}");else if(t==="%GeneratorFunction%")s=Jr("function* () {}");else if(t==="%AsyncGeneratorFunction%")s=Jr("async function* () {}");else if(t==="%AsyncGenerator%"){var n=e("%AsyncGeneratorFunction%");n&&(s=n.prototype)}else if(t==="%AsyncIteratorPrototype%"){var a=e("%AsyncGenerator%");a&&_&&(s=_(a.prototype))}return be[t]=s,s},Ao={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},Ye=he(),gt=zr(),HP=Ye.call(je,Array.prototype.concat),QP=Ye.call(To,Array.prototype.splice),Co=Ye.call(je,String.prototype.replace),yt=Ye.call(je,String.prototype.slice),DP=Ye.call(je,RegExp.prototype.exec),FP=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,MP=/\\(\\)?/g,OP=function(t){var s=yt(t,0,1),n=yt(t,-1);if(s==="%"&&n!=="%")throw new We("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&s!=="%")throw new We("invalid intrinsic syntax, expected opening `%`");var a=[];return Co(t,FP,function(o,i,p,u){a[a.length]=p?Co(u,MP,"$1"):i||o}),a},VP=function(t,s){var n=t,a;if(gt(Ao,n)&&(a=Ao[n],n="%"+a[0]+"%"),gt(be,n)){var o=be[n];if(o===Ee&&(o=_P(n)),typeof o>"u"&&!s)throw new Le("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:a,name:n,value:o}}throw new We("intrinsic "+t+" does not exist!")};wo.exports=function(t,s){if(typeof t!="string"||t.length===0)throw new Le("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof s!="boolean")throw new Le('"allowMissing" argument must be a boolean');if(DP(/^%?[^%]*%?$/,t)===null)throw new We("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=OP(t),a=n.length>0?n[0]:"",o=VP("%"+a+"%",s),i=o.name,p=o.value,u=!1,r=o.alias;r&&(a=r[0],QP(n,HP([0,1],r)));for(var y=1,x=!0;y<n.length;y+=1){var m=n[y],k=yt(m,0,1),P=yt(m,-1);if((k==='"'||k==="'"||k==="`"||P==='"'||P==="'"||P==="`")&&k!==P)throw new We("property names with quotes must have matching quotes");if((m==="constructor"||!x)&&(u=!0),a+="."+m,i="%"+a+"%",gt(be,i))p=be[i];else if(p!=null){if(!(m in p)){if(!s)throw new Le("base intrinsic for "+t+" exists, but the property is not available.");return}if(Je&&y+1>=n.length){var q=Je(p,m);x=!!q,x&&"get"in q&&!("originalValue"in q.get)?p=q.get:p=p[m]}else x=gt(p,m),p=p[m];x&&!u&&(be[i]=p)}}return p}});var qt=h((dB,_o)=>{"use strict";var v,NP=ot(),KP=Sr(),$P=Er(),zP=Lr(),JP=Wr(),De=it(),Qe=qe(),jP=_r(),YP=Hr(),ZP=Qr(),XP=Dr(),ev=Fr(),tv=Mr(),rv=Or(),sv=Vr(),Lo=Function,Yr=function(e){try{return Lo('"use strict"; return ('+e+").constructor;")()}catch{}},Ze=Ue(),nv=Ge(),Zr=function(){throw new Qe},av=Ze?(function(){try{return arguments.callee,Zr}catch{try{return Ze(arguments,"callee").get}catch{return Zr}}})():Zr,_e=Nr()(),H=$r(),ov=dt(),iv=ct(),Wo=lt(),Xe=ze(),He={},pv=typeof Uint8Array>"u"||!H?v:H(Uint8Array),fe={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?v:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?v:ArrayBuffer,"%ArrayIteratorPrototype%":_e&&H?H([][Symbol.iterator]()):v,"%AsyncFromSyncIteratorPrototype%":v,"%AsyncFunction%":He,"%AsyncGenerator%":He,"%AsyncGeneratorFunction%":He,"%AsyncIteratorPrototype%":He,"%Atomics%":typeof Atomics>"u"?v:Atomics,"%BigInt%":typeof BigInt>"u"?v:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?v:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?v:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?v:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":KP,"%eval%":eval,"%EvalError%":$P,"%Float16Array%":typeof Float16Array>"u"?v:Float16Array,"%Float32Array%":typeof Float32Array>"u"?v:Float32Array,"%Float64Array%":typeof Float64Array>"u"?v:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?v:FinalizationRegistry,"%Function%":Lo,"%GeneratorFunction%":He,"%Int8Array%":typeof Int8Array>"u"?v:Int8Array,"%Int16Array%":typeof Int16Array>"u"?v:Int16Array,"%Int32Array%":typeof Int32Array>"u"?v:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":_e&&H?H(H([][Symbol.iterator]())):v,"%JSON%":typeof JSON=="object"?JSON:v,"%Map%":typeof Map>"u"?v:Map,"%MapIteratorPrototype%":typeof Map>"u"||!_e||!H?v:H(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":NP,"%Object.getOwnPropertyDescriptor%":Ze,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?v:Promise,"%Proxy%":typeof Proxy>"u"?v:Proxy,"%RangeError%":zP,"%ReferenceError%":JP,"%Reflect%":typeof Reflect>"u"?v:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?v:Set,"%SetIteratorPrototype%":typeof Set>"u"||!_e||!H?v:H(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?v:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":_e&&H?H(""[Symbol.iterator]()):v,"%Symbol%":_e?Symbol:v,"%SyntaxError%":De,"%ThrowTypeError%":av,"%TypedArray%":pv,"%TypeError%":Qe,"%Uint8Array%":typeof Uint8Array>"u"?v:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?v:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?v:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?v:Uint32Array,"%URIError%":jP,"%WeakMap%":typeof WeakMap>"u"?v:WeakMap,"%WeakRef%":typeof WeakRef>"u"?v:WeakRef,"%WeakSet%":typeof WeakSet>"u"?v:WeakSet,"%Function.prototype.call%":Xe,"%Function.prototype.apply%":Wo,"%Object.defineProperty%":nv,"%Object.getPrototypeOf%":ov,"%Math.abs%":YP,"%Math.floor%":ZP,"%Math.max%":XP,"%Math.min%":ev,"%Math.pow%":tv,"%Math.round%":rv,"%Math.sign%":sv,"%Reflect.getPrototypeOf%":iv};if(H)try{null.error}catch(e){Go=H(H(e)),fe["%Error.prototype%"]=Go}var Go,uv=function e(t){var s;if(t==="%AsyncFunction%")s=Yr("async function () {}");else if(t==="%GeneratorFunction%")s=Yr("function* () {}");else if(t==="%AsyncGeneratorFunction%")s=Yr("async function* () {}");else if(t==="%AsyncGenerator%"){var n=e("%AsyncGeneratorFunction%");n&&(s=n.prototype)}else if(t==="%AsyncIteratorPrototype%"){var a=e("%AsyncGenerator%");a&&H&&(s=H(a.prototype))}return fe[t]=s,s},So={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},et=he(),mt=zr(),cv=et.call(Xe,Array.prototype.concat),dv=et.call(Wo,Array.prototype.splice),Eo=et.call(Xe,String.prototype.replace),Rt=et.call(Xe,String.prototype.slice),lv=et.call(Xe,RegExp.prototype.exec),gv=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,yv=/\\(\\)?/g,mv=function(t){var s=Rt(t,0,1),n=Rt(t,-1);if(s==="%"&&n!=="%")throw new De("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&s!=="%")throw new De("invalid intrinsic syntax, expected opening `%`");var a=[];return Eo(t,gv,function(o,i,p,u){a[a.length]=p?Eo(u,yv,"$1"):i||o}),a},Rv=function(t,s){var n=t,a;if(mt(So,n)&&(a=So[n],n="%"+a[0]+"%"),mt(fe,n)){var o=fe[n];if(o===He&&(o=uv(n)),typeof o>"u"&&!s)throw new Qe("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:a,name:n,value:o}}throw new De("intrinsic "+t+" does not exist!")};_o.exports=function(t,s){if(typeof t!="string"||t.length===0)throw new Qe("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof s!="boolean")throw new Qe('"allowMissing" argument must be a boolean');if(lv(/^%?[^%]*%?$/,t)===null)throw new De("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=mv(t),a=n.length>0?n[0]:"",o=Rv("%"+a+"%",s),i=o.name,p=o.value,u=!1,r=o.alias;r&&(a=r[0],dv(n,cv([0,1],r)));for(var y=1,x=!0;y<n.length;y+=1){var m=n[y],k=Rt(m,0,1),P=Rt(m,-1);if((k==='"'||k==="'"||k==="`"||P==='"'||P==="'"||P==="`")&&k!==P)throw new De("property names with quotes must have matching quotes");if((m==="constructor"||!x)&&(u=!0),a+="."+m,i="%"+a+"%",mt(fe,i))p=fe[i];else if(p!=null){if(!(m in p)){if(!s)throw new Qe("base intrinsic for "+t+" exists, but the property is not available.");return}if(Ze&&y+1>=n.length){var q=Ze(p,m);x=!!q,x&&"get"in q&&!("originalValue"in q.get)?p=q.get:p=p[m]}else x=mt(p,m),p=p[m];x&&!u&&(fe[i]=p)}}return p}});var Fo=h((lB,Do)=>{"use strict";var Ho=Ge(),qv=it(),Fe=qe(),Qo=Ue();Do.exports=function(t,s,n){if(!t||typeof t!="object"&&typeof t!="function")throw new Fe("`obj` must be an object or a function`");if(typeof s!="string"&&typeof s!="symbol")throw new Fe("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new Fe("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new Fe("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new Fe("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new Fe("`loose`, if provided, must be a boolean");var a=arguments.length>3?arguments[3]:null,o=arguments.length>4?arguments[4]:null,i=arguments.length>5?arguments[5]:null,p=arguments.length>6?arguments[6]:!1,u=!!Qo&&Qo(t,s);if(Ho)Ho(t,s,{configurable:i===null&&u?u.configurable:!i,enumerable:a===null&&u?u.enumerable:!a,value:n,writable:o===null&&u?u.writable:!o});else if(p||!a&&!o&&!i)t[s]=n;else throw new qv("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")}});var Vo=h((gB,Oo)=>{"use strict";var Xr=Ge(),Mo=function(){return!!Xr};Mo.hasArrayLengthDefineBug=function(){if(!Xr)return null;try{return Xr([],"length",{value:1}).length!==1}catch{return!0}};Oo.exports=Mo});var Jo=h((yB,zo)=>{"use strict";var hv=qt(),No=Fo(),bv=Vo()(),Ko=Ue(),$o=qe(),fv=hv("%Math.floor%");zo.exports=function(t,s){if(typeof t!="function")throw new $o("`fn` is not a function");if(typeof s!="number"||s<0||s>4294967295||fv(s)!==s)throw new $o("`length` must be a positive 32-bit integer");var n=arguments.length>2&&!!arguments[2],a=!0,o=!0;if("length"in t&&Ko){var i=Ko(t,"length");i&&!i.configurable&&(a=!1),i&&!i.writable&&(o=!1)}return(a||o||!n)&&(bv?No(t,"length",s,!0,!0):No(t,"length",s)),t}});var ti=h((mB,ht)=>{"use strict";var es=he(),bt=qt(),Iv=Jo(),xv=qe(),Zo=bt("%Function.prototype.apply%"),Xo=bt("%Function.prototype.call%"),ei=bt("%Reflect.apply%",!0)||es.call(Xo,Zo),jo=Ge(),kv=bt("%Math.max%");ht.exports=function(t){if(typeof t!="function")throw new xv("a function is required");var s=ei(es,Xo,arguments);return Iv(s,1+kv(0,t.length-(arguments.length-1)),!0)};var Yo=function(){return ei(es,Zo,arguments)};jo?jo(ht.exports,"apply",{value:Yo}):ht.exports.apply=Yo});var ai=h((RB,ni)=>{"use strict";var ri=qt(),si=ti(),Pv=si(ri("String.prototype.indexOf"));ni.exports=function(t,s){var n=ri(t,!!s);return typeof n=="function"&&Pv(t,".prototype.")>-1?si(n):n}});var oi=h(()=>{});var Ci=h((bB,Ai)=>{var cs=typeof Map=="function"&&Map.prototype,ts=Object.getOwnPropertyDescriptor&&cs?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,It=cs&&ts&&typeof ts.get=="function"?ts.get:null,ii=cs&&Map.prototype.forEach,ds=typeof Set=="function"&&Set.prototype,rs=Object.getOwnPropertyDescriptor&&ds?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,xt=ds&&rs&&typeof rs.get=="function"?rs.get:null,pi=ds&&Set.prototype.forEach,vv=typeof WeakMap=="function"&&WeakMap.prototype,rt=vv?WeakMap.prototype.has:null,Av=typeof WeakSet=="function"&&WeakSet.prototype,st=Av?WeakSet.prototype.has:null,Cv=typeof WeakRef=="function"&&WeakRef.prototype,ui=Cv?WeakRef.prototype.deref:null,Bv=Boolean.prototype.valueOf,Tv=Object.prototype.toString,wv=Function.prototype.toString,Uv=String.prototype.match,ls=String.prototype.slice,pe=String.prototype.replace,Gv=String.prototype.toUpperCase,ci=String.prototype.toLowerCase,bi=RegExp.prototype.test,di=Array.prototype.concat,Z=Array.prototype.join,Sv=Array.prototype.slice,li=Math.floor,as=typeof BigInt=="function"?BigInt.prototype.valueOf:null,ss=Object.getOwnPropertySymbols,os=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,Me=typeof Symbol=="function"&&typeof Symbol.iterator=="object",O=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===Me||!0)?Symbol.toStringTag:null,fi=Object.prototype.propertyIsEnumerable,gi=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function yi(e,t){if(e===1/0||e===-1/0||e!==e||e&&e>-1e3&&e<1e3||bi.call(/e/,t))return t;var s=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof e=="number"){var n=e<0?-li(-e):li(e);if(n!==e){var a=String(n),o=ls.call(t,a.length+1);return pe.call(a,s,"$&_")+"."+pe.call(pe.call(o,/([0-9]{3})/g,"$&_"),/_$/,"")}}return pe.call(t,s,"$&_")}var is=oi(),mi=is.custom,Ri=ki(mi)?mi:null,Ii={__proto__:null,double:'"',single:"'"},Ev={__proto__:null,double:/(["\\])/g,single:/(['\\])/g};Ai.exports=function e(t,s,n,a){var o=s||{};if(re(o,"quoteStyle")&&!re(Ii,o.quoteStyle))throw new TypeError('option "quoteStyle" must be "single" or "double"');if(re(o,"maxStringLength")&&(typeof o.maxStringLength=="number"?o.maxStringLength<0&&o.maxStringLength!==1/0:o.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var i=re(o,"customInspect")?o.customInspect:!0;if(typeof i!="boolean"&&i!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(re(o,"indent")&&o.indent!==null&&o.indent!==" "&&!(parseInt(o.indent,10)===o.indent&&o.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(re(o,"numericSeparator")&&typeof o.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var p=o.numericSeparator;if(typeof t>"u")return"undefined";if(t===null)return"null";if(typeof t=="boolean")return t?"true":"false";if(typeof t=="string")return vi(t,o);if(typeof t=="number"){if(t===0)return 1/0/t>0?"0":"-0";var u=String(t);return p?yi(t,u):u}if(typeof t=="bigint"){var r=String(t)+"n";return p?yi(t,r):r}var y=typeof o.depth>"u"?5:o.depth;if(typeof n>"u"&&(n=0),n>=y&&y>0&&typeof t=="object")return ps(t)?"[Array]":"[Object]";var x=Zv(o,n);if(typeof a>"u")a=[];else if(Pi(a,t)>=0)return"[Circular]";function m(Y,ae,ee){if(ae&&(a=Sv.call(a),a.push(ae)),ee){var $e={depth:o.depth};return re(o,"quoteStyle")&&($e.quoteStyle=o.quoteStyle),e(Y,$e,n+1,a)}return e(Y,o,n+1,a)}if(typeof t=="function"&&!qi(t)){var k=Ov(t),P=ft(t,m);return"[Function"+(k?": "+k:" (anonymous)")+"]"+(P.length>0?" { "+Z.call(P,", ")+" }":"")}if(ki(t)){var q=Me?pe.call(String(t),/^(Symbol\(.*\))_[^)]*$/,"$1"):os.call(t);return typeof t=="object"&&!Me?tt(q):q}if(Jv(t)){for(var L="<"+ci.call(String(t.nodeName)),I=t.attributes||[],K=0;K<I.length;K++)L+=" "+I[K].name+"="+xi(Lv(I[K].value),"double",o);return L+=">",t.childNodes&&t.childNodes.length&&(L+="..."),L+="</"+ci.call(String(t.nodeName))+">",L}if(ps(t)){if(t.length===0)return"[]";var J=ft(t,m);return x&&!Yv(J)?"["+us(J,x)+"]":"[ "+Z.call(J,", ")+" ]"}if(_v(t)){var j=ft(t,m);return!("cause"in Error.prototype)&&"cause"in t&&!fi.call(t,"cause")?"{ ["+String(t)+"] "+Z.call(di.call("[cause]: "+m(t.cause),j),", ")+" }":j.length===0?"["+String(t)+"]":"{ ["+String(t)+"] "+Z.call(j,", ")+" }"}if(typeof t=="object"&&i){if(Ri&&typeof t[Ri]=="function"&&is)return is(t,{depth:y-n});if(i!=="symbol"&&typeof t.inspect=="function")return t.inspect()}if(Vv(t)){var ce=[];return ii&&ii.call(t,function(Y,ae){ce.push(m(ae,t,!0)+" => "+m(Y,t))}),hi("Map",It.call(t),ce,x)}if($v(t)){var Ne=[];return pi&&pi.call(t,function(Y){Ne.push(m(Y,t))}),hi("Set",xt.call(t),Ne,x)}if(Nv(t))return ns("WeakMap");if(zv(t))return ns("WeakSet");if(Kv(t))return ns("WeakRef");if(Qv(t))return tt(m(Number(t)));if(Fv(t))return tt(m(as.call(t)));if(Dv(t))return tt(Bv.call(t));if(Hv(t))return tt(m(String(t)));if(typeof window<"u"&&t===window)return"{ [object Window] }";if(typeof globalThis<"u"&&t===globalThis||typeof global<"u"&&t===global)return"{ [object globalThis] }";if(!Wv(t)&&!qi(t)){var de=ft(t,m),Ke=gi?gi(t)===Object.prototype:t instanceof Object||t.constructor===Object,ne=t instanceof Object?"":"null prototype",Ce=!Ke&&O&&Object(t)===t&&O in t?ls.call(ue(t),8,-1):ne?"Object":"",le=Ke||typeof t.constructor!="function"?"":t.constructor.name?t.constructor.name+" ":"",Be=le+(Ce||ne?"["+Z.call(di.call([],Ce||[],ne||[]),": ")+"] ":"");return de.length===0?Be+"{}":x?Be+"{"+us(de,x)+"}":Be+"{ "+Z.call(de,", ")+" }"}return String(t)};function xi(e,t,s){var n=s.quoteStyle||t,a=Ii[n];return a+e+a}function Lv(e){return pe.call(String(e),/"/g,"&quot;")}function ps(e){return ue(e)==="[object Array]"&&(!O||!(typeof e=="object"&&O in e))}function Wv(e){return ue(e)==="[object Date]"&&(!O||!(typeof e=="object"&&O in e))}function qi(e){return ue(e)==="[object RegExp]"&&(!O||!(typeof e=="object"&&O in e))}function _v(e){return ue(e)==="[object Error]"&&(!O||!(typeof e=="object"&&O in e))}function Hv(e){return ue(e)==="[object String]"&&(!O||!(typeof e=="object"&&O in e))}function Qv(e){return ue(e)==="[object Number]"&&(!O||!(typeof e=="object"&&O in e))}function Dv(e){return ue(e)==="[object Boolean]"&&(!O||!(typeof e=="object"&&O in e))}function ki(e){if(Me)return e&&typeof e=="object"&&e instanceof Symbol;if(typeof e=="symbol")return!0;if(!e||typeof e!="object"||!os)return!1;try{return os.call(e),!0}catch{}return!1}function Fv(e){if(!e||typeof e!="object"||!as)return!1;try{return as.call(e),!0}catch{}return!1}var Mv=Object.prototype.hasOwnProperty||function(e){return e in this};function re(e,t){return Mv.call(e,t)}function ue(e){return Tv.call(e)}function Ov(e){if(e.name)return e.name;var t=Uv.call(wv.call(e),/^function\s*([\w$]+)/);return t?t[1]:null}function Pi(e,t){if(e.indexOf)return e.indexOf(t);for(var s=0,n=e.length;s<n;s++)if(e[s]===t)return s;return-1}function Vv(e){if(!It||!e||typeof e!="object")return!1;try{It.call(e);try{xt.call(e)}catch{return!0}return e instanceof Map}catch{}return!1}function Nv(e){if(!rt||!e||typeof e!="object")return!1;try{rt.call(e,rt);try{st.call(e,st)}catch{return!0}return e instanceof WeakMap}catch{}return!1}function Kv(e){if(!ui||!e||typeof e!="object")return!1;try{return ui.call(e),!0}catch{}return!1}function $v(e){if(!xt||!e||typeof e!="object")return!1;try{xt.call(e);try{It.call(e)}catch{return!0}return e instanceof Set}catch{}return!1}function zv(e){if(!st||!e||typeof e!="object")return!1;try{st.call(e,st);try{rt.call(e,rt)}catch{return!0}return e instanceof WeakSet}catch{}return!1}function Jv(e){return!e||typeof e!="object"?!1:typeof HTMLElement<"u"&&e instanceof HTMLElement?!0:typeof e.nodeName=="string"&&typeof e.getAttribute=="function"}function vi(e,t){if(e.length>t.maxStringLength){var s=e.length-t.maxStringLength,n="... "+s+" more character"+(s>1?"s":"");return vi(ls.call(e,0,t.maxStringLength),t)+n}var a=Ev[t.quoteStyle||"single"];a.lastIndex=0;var o=pe.call(pe.call(e,a,"\\$1"),/[\x00-\x1f]/g,jv);return xi(o,"single",t)}function jv(e){var t=e.charCodeAt(0),s={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return s?"\\"+s:"\\x"+(t<16?"0":"")+Gv.call(t.toString(16))}function tt(e){return"Object("+e+")"}function ns(e){return e+" { ? }"}function hi(e,t,s,n){var a=n?us(s,n):Z.call(s,", ");return e+" ("+t+") {"+a+"}"}function Yv(e){for(var t=0;t<e.length;t++)if(Pi(e[t],`
2
- `)>=0)return!1;return!0}function Zv(e,t){var s;if(e.indent===" ")s=" ";else if(typeof e.indent=="number"&&e.indent>0)s=Z.call(Array(e.indent+1)," ");else return null;return{base:s,prev:Z.call(Array(t+1),s)}}function us(e,t){if(e.length===0)return"";var s=`
1
+ var lk=Object.create;var Et=Object.defineProperty;var gk=Object.getOwnPropertyDescriptor;var yk=Object.getOwnPropertyNames;var mk=Object.getPrototypeOf,Rk=Object.prototype.hasOwnProperty;var h=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),te=(e,t)=>{for(var s in t)Et(e,s,{get:t[s],enumerable:!0})},qk=(e,t,s,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of yk(t))!Rk.call(e,a)&&a!==s&&Et(e,a,{get:()=>t[a],enumerable:!(n=gk(t,a))||n.enumerable});return e};var Te=(e,t,s)=>(s=e!=null?lk(mk(e)):{},qk(t||!e||!e.__esModule?Et(s,"default",{value:e,enumerable:!0}):s,e));var ot=h((LC,Ba)=>{"use strict";Ba.exports=Object});var Sr=h((WC,Ta)=>{"use strict";Ta.exports=Error});var Er=h((_C,wa)=>{"use strict";wa.exports=EvalError});var Lr=h((HC,Ua)=>{"use strict";Ua.exports=RangeError});var Wr=h((QC,Ga)=>{"use strict";Ga.exports=ReferenceError});var it=h((DC,Sa)=>{"use strict";Sa.exports=SyntaxError});var qe=h((FC,Ea)=>{"use strict";Ea.exports=TypeError});var _r=h((MC,La)=>{"use strict";La.exports=URIError});var Hr=h((OC,Wa)=>{"use strict";Wa.exports=Math.abs});var Qr=h((VC,_a)=>{"use strict";_a.exports=Math.floor});var Dr=h((NC,Ha)=>{"use strict";Ha.exports=Math.max});var Fr=h((KC,Qa)=>{"use strict";Qa.exports=Math.min});var Mr=h(($C,Da)=>{"use strict";Da.exports=Math.pow});var Or=h((zC,Fa)=>{"use strict";Fa.exports=Math.round});var Oa=h((JC,Ma)=>{"use strict";Ma.exports=Number.isNaN||function(t){return t!==t}});var Vr=h((jC,Va)=>{"use strict";var tP=Oa();Va.exports=function(t){return tP(t)||t===0?t:t<0?-1:1}});var Ka=h((YC,Na)=>{"use strict";Na.exports=Object.getOwnPropertyDescriptor});var Ue=h((ZC,$a)=>{"use strict";var pt=Ka();if(pt)try{pt([],"length")}catch{pt=null}$a.exports=pt});var Ge=h((XC,za)=>{"use strict";var ut=Object.defineProperty||!1;if(ut)try{ut({},"a",{value:1})}catch{ut=!1}za.exports=ut});var ja=h((eB,Ja)=>{"use strict";Ja.exports=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var t={},s=Symbol("test"),n=Object(s);if(typeof s=="string"||Object.prototype.toString.call(s)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var a=42;t[s]=a;for(var o in t)return!1;if(typeof Object.keys=="function"&&Object.keys(t).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(t).length!==0)return!1;var i=Object.getOwnPropertySymbols(t);if(i.length!==1||i[0]!==s||!Object.prototype.propertyIsEnumerable.call(t,s))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var p=Object.getOwnPropertyDescriptor(t,s);if(p.value!==a||p.enumerable!==!0)return!1}return!0}});var Nr=h((tB,Za)=>{"use strict";var Ya=typeof Symbol<"u"&&Symbol,rP=ja();Za.exports=function(){return typeof Ya!="function"||typeof Symbol!="function"||typeof Ya("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:rP()}});var ct=h((rB,Xa)=>{"use strict";Xa.exports=typeof Reflect<"u"&&Reflect.getPrototypeOf||null});var dt=h((sB,eo)=>{"use strict";var sP=ot();eo.exports=sP.getPrototypeOf||null});var so=h((nB,ro)=>{"use strict";var nP="Function.prototype.bind called on incompatible ",aP=Object.prototype.toString,oP=Math.max,iP="[object Function]",to=function(t,s){for(var n=[],a=0;a<t.length;a+=1)n[a]=t[a];for(var o=0;o<s.length;o+=1)n[o+t.length]=s[o];return n},pP=function(t,s){for(var n=[],a=s||0,o=0;a<t.length;a+=1,o+=1)n[o]=t[a];return n},uP=function(e,t){for(var s="",n=0;n<e.length;n+=1)s+=e[n],n+1<e.length&&(s+=t);return s};ro.exports=function(t){var s=this;if(typeof s!="function"||aP.apply(s)!==iP)throw new TypeError(nP+s);for(var n=pP(arguments,1),a,o=function(){if(this instanceof a){var y=s.apply(this,to(n,arguments));return Object(y)===y?y:this}return s.apply(t,to(n,arguments))},i=oP(0,s.length-n.length),p=[],u=0;u<i;u++)p[u]="$"+u;if(a=Function("binder","return function ("+uP(p,",")+"){ return binder.apply(this,arguments); }")(o),s.prototype){var r=function(){};r.prototype=s.prototype,a.prototype=new r,r.prototype=null}return a}});var he=h((aB,no)=>{"use strict";var cP=so();no.exports=Function.prototype.bind||cP});var ze=h((oB,ao)=>{"use strict";ao.exports=Function.prototype.call});var lt=h((iB,oo)=>{"use strict";oo.exports=Function.prototype.apply});var po=h((pB,io)=>{"use strict";io.exports=typeof Reflect<"u"&&Reflect&&Reflect.apply});var co=h((uB,uo)=>{"use strict";var dP=he(),lP=lt(),gP=ze(),yP=po();uo.exports=yP||dP.call(gP,lP)});var go=h((cB,lo)=>{"use strict";var mP=he(),RP=qe(),qP=ze(),hP=co();lo.exports=function(t){if(t.length<1||typeof t[0]!="function")throw new RP("a function is required");return hP(mP,qP,t)}});var bo=h((dB,ho)=>{"use strict";var bP=go(),yo=Ue(),Ro;try{Ro=[].__proto__===Array.prototype}catch(e){if(!e||typeof e!="object"||!("code"in e)||e.code!=="ERR_PROTO_ACCESS")throw e}var Kr=!!Ro&&yo&&yo(Object.prototype,"__proto__"),qo=Object,mo=qo.getPrototypeOf;ho.exports=Kr&&typeof Kr.get=="function"?bP([Kr.get]):typeof mo=="function"?function(t){return mo(t==null?t:qo(t))}:!1});var $r=h((lB,ko)=>{"use strict";var fo=ct(),Io=dt(),xo=bo();ko.exports=fo?function(t){return fo(t)}:Io?function(t){if(!t||typeof t!="object"&&typeof t!="function")throw new TypeError("getProto: not an object");return Io(t)}:xo?function(t){return xo(t)}:null});var zr=h((gB,Po)=>{"use strict";var fP=Function.prototype.call,IP=Object.prototype.hasOwnProperty,xP=he();Po.exports=xP.call(fP,IP)});var Uo=h((yB,wo)=>{"use strict";var A,kP=ot(),PP=Sr(),vP=Er(),AP=Lr(),CP=Wr(),We=it(),Le=qe(),BP=_r(),TP=Hr(),wP=Qr(),UP=Dr(),GP=Fr(),SP=Mr(),EP=Or(),LP=Vr(),Bo=Function,Jr=function(e){try{return Bo('"use strict"; return ('+e+").constructor;")()}catch{}},Je=Ue(),WP=Ge(),jr=function(){throw new Le},_P=Je?(function(){try{return arguments.callee,jr}catch{try{return Je(arguments,"callee").get}catch{return jr}}})():jr,Se=Nr()(),_=$r(),HP=dt(),QP=ct(),To=lt(),je=ze(),Ee={},DP=typeof Uint8Array>"u"||!_?A:_(Uint8Array),be={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?A:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?A:ArrayBuffer,"%ArrayIteratorPrototype%":Se&&_?_([][Symbol.iterator]()):A,"%AsyncFromSyncIteratorPrototype%":A,"%AsyncFunction%":Ee,"%AsyncGenerator%":Ee,"%AsyncGeneratorFunction%":Ee,"%AsyncIteratorPrototype%":Ee,"%Atomics%":typeof Atomics>"u"?A:Atomics,"%BigInt%":typeof BigInt>"u"?A:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?A:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?A:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?A:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":PP,"%eval%":eval,"%EvalError%":vP,"%Float32Array%":typeof Float32Array>"u"?A:Float32Array,"%Float64Array%":typeof Float64Array>"u"?A:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?A:FinalizationRegistry,"%Function%":Bo,"%GeneratorFunction%":Ee,"%Int8Array%":typeof Int8Array>"u"?A:Int8Array,"%Int16Array%":typeof Int16Array>"u"?A:Int16Array,"%Int32Array%":typeof Int32Array>"u"?A:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":Se&&_?_(_([][Symbol.iterator]())):A,"%JSON%":typeof JSON=="object"?JSON:A,"%Map%":typeof Map>"u"?A:Map,"%MapIteratorPrototype%":typeof Map>"u"||!Se||!_?A:_(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":kP,"%Object.getOwnPropertyDescriptor%":Je,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?A:Promise,"%Proxy%":typeof Proxy>"u"?A:Proxy,"%RangeError%":AP,"%ReferenceError%":CP,"%Reflect%":typeof Reflect>"u"?A:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?A:Set,"%SetIteratorPrototype%":typeof Set>"u"||!Se||!_?A:_(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?A:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":Se&&_?_(""[Symbol.iterator]()):A,"%Symbol%":Se?Symbol:A,"%SyntaxError%":We,"%ThrowTypeError%":_P,"%TypedArray%":DP,"%TypeError%":Le,"%Uint8Array%":typeof Uint8Array>"u"?A:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?A:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?A:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?A:Uint32Array,"%URIError%":BP,"%WeakMap%":typeof WeakMap>"u"?A:WeakMap,"%WeakRef%":typeof WeakRef>"u"?A:WeakRef,"%WeakSet%":typeof WeakSet>"u"?A:WeakSet,"%Function.prototype.call%":je,"%Function.prototype.apply%":To,"%Object.defineProperty%":WP,"%Object.getPrototypeOf%":HP,"%Math.abs%":TP,"%Math.floor%":wP,"%Math.max%":UP,"%Math.min%":GP,"%Math.pow%":SP,"%Math.round%":EP,"%Math.sign%":LP,"%Reflect.getPrototypeOf%":QP};if(_)try{null.error}catch(e){vo=_(_(e)),be["%Error.prototype%"]=vo}var vo,FP=function e(t){var s;if(t==="%AsyncFunction%")s=Jr("async function () {}");else if(t==="%GeneratorFunction%")s=Jr("function* () {}");else if(t==="%AsyncGeneratorFunction%")s=Jr("async function* () {}");else if(t==="%AsyncGenerator%"){var n=e("%AsyncGeneratorFunction%");n&&(s=n.prototype)}else if(t==="%AsyncIteratorPrototype%"){var a=e("%AsyncGenerator%");a&&_&&(s=_(a.prototype))}return be[t]=s,s},Ao={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},Ye=he(),gt=zr(),MP=Ye.call(je,Array.prototype.concat),OP=Ye.call(To,Array.prototype.splice),Co=Ye.call(je,String.prototype.replace),yt=Ye.call(je,String.prototype.slice),VP=Ye.call(je,RegExp.prototype.exec),NP=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,KP=/\\(\\)?/g,$P=function(t){var s=yt(t,0,1),n=yt(t,-1);if(s==="%"&&n!=="%")throw new We("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&s!=="%")throw new We("invalid intrinsic syntax, expected opening `%`");var a=[];return Co(t,NP,function(o,i,p,u){a[a.length]=p?Co(u,KP,"$1"):i||o}),a},zP=function(t,s){var n=t,a;if(gt(Ao,n)&&(a=Ao[n],n="%"+a[0]+"%"),gt(be,n)){var o=be[n];if(o===Ee&&(o=FP(n)),typeof o>"u"&&!s)throw new Le("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:a,name:n,value:o}}throw new We("intrinsic "+t+" does not exist!")};wo.exports=function(t,s){if(typeof t!="string"||t.length===0)throw new Le("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof s!="boolean")throw new Le('"allowMissing" argument must be a boolean');if(VP(/^%?[^%]*%?$/,t)===null)throw new We("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=$P(t),a=n.length>0?n[0]:"",o=zP("%"+a+"%",s),i=o.name,p=o.value,u=!1,r=o.alias;r&&(a=r[0],OP(n,MP([0,1],r)));for(var y=1,x=!0;y<n.length;y+=1){var m=n[y],k=yt(m,0,1),P=yt(m,-1);if((k==='"'||k==="'"||k==="`"||P==='"'||P==="'"||P==="`")&&k!==P)throw new We("property names with quotes must have matching quotes");if((m==="constructor"||!x)&&(u=!0),a+="."+m,i="%"+a+"%",gt(be,i))p=be[i];else if(p!=null){if(!(m in p)){if(!s)throw new Le("base intrinsic for "+t+" exists, but the property is not available.");return}if(Je&&y+1>=n.length){var q=Je(p,m);x=!!q,x&&"get"in q&&!("originalValue"in q.get)?p=q.get:p=p[m]}else x=gt(p,m),p=p[m];x&&!u&&(be[i]=p)}}return p}});var qt=h((mB,_o)=>{"use strict";var v,JP=ot(),jP=Sr(),YP=Er(),ZP=Lr(),XP=Wr(),De=it(),Qe=qe(),ev=_r(),tv=Hr(),rv=Qr(),sv=Dr(),nv=Fr(),av=Mr(),ov=Or(),iv=Vr(),Lo=Function,Yr=function(e){try{return Lo('"use strict"; return ('+e+").constructor;")()}catch{}},Ze=Ue(),pv=Ge(),Zr=function(){throw new Qe},uv=Ze?(function(){try{return arguments.callee,Zr}catch{try{return Ze(arguments,"callee").get}catch{return Zr}}})():Zr,_e=Nr()(),H=$r(),cv=dt(),dv=ct(),Wo=lt(),Xe=ze(),He={},lv=typeof Uint8Array>"u"||!H?v:H(Uint8Array),fe={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?v:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?v:ArrayBuffer,"%ArrayIteratorPrototype%":_e&&H?H([][Symbol.iterator]()):v,"%AsyncFromSyncIteratorPrototype%":v,"%AsyncFunction%":He,"%AsyncGenerator%":He,"%AsyncGeneratorFunction%":He,"%AsyncIteratorPrototype%":He,"%Atomics%":typeof Atomics>"u"?v:Atomics,"%BigInt%":typeof BigInt>"u"?v:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?v:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?v:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?v:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":jP,"%eval%":eval,"%EvalError%":YP,"%Float16Array%":typeof Float16Array>"u"?v:Float16Array,"%Float32Array%":typeof Float32Array>"u"?v:Float32Array,"%Float64Array%":typeof Float64Array>"u"?v:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?v:FinalizationRegistry,"%Function%":Lo,"%GeneratorFunction%":He,"%Int8Array%":typeof Int8Array>"u"?v:Int8Array,"%Int16Array%":typeof Int16Array>"u"?v:Int16Array,"%Int32Array%":typeof Int32Array>"u"?v:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":_e&&H?H(H([][Symbol.iterator]())):v,"%JSON%":typeof JSON=="object"?JSON:v,"%Map%":typeof Map>"u"?v:Map,"%MapIteratorPrototype%":typeof Map>"u"||!_e||!H?v:H(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":JP,"%Object.getOwnPropertyDescriptor%":Ze,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?v:Promise,"%Proxy%":typeof Proxy>"u"?v:Proxy,"%RangeError%":ZP,"%ReferenceError%":XP,"%Reflect%":typeof Reflect>"u"?v:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?v:Set,"%SetIteratorPrototype%":typeof Set>"u"||!_e||!H?v:H(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?v:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":_e&&H?H(""[Symbol.iterator]()):v,"%Symbol%":_e?Symbol:v,"%SyntaxError%":De,"%ThrowTypeError%":uv,"%TypedArray%":lv,"%TypeError%":Qe,"%Uint8Array%":typeof Uint8Array>"u"?v:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?v:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?v:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?v:Uint32Array,"%URIError%":ev,"%WeakMap%":typeof WeakMap>"u"?v:WeakMap,"%WeakRef%":typeof WeakRef>"u"?v:WeakRef,"%WeakSet%":typeof WeakSet>"u"?v:WeakSet,"%Function.prototype.call%":Xe,"%Function.prototype.apply%":Wo,"%Object.defineProperty%":pv,"%Object.getPrototypeOf%":cv,"%Math.abs%":tv,"%Math.floor%":rv,"%Math.max%":sv,"%Math.min%":nv,"%Math.pow%":av,"%Math.round%":ov,"%Math.sign%":iv,"%Reflect.getPrototypeOf%":dv};if(H)try{null.error}catch(e){Go=H(H(e)),fe["%Error.prototype%"]=Go}var Go,gv=function e(t){var s;if(t==="%AsyncFunction%")s=Yr("async function () {}");else if(t==="%GeneratorFunction%")s=Yr("function* () {}");else if(t==="%AsyncGeneratorFunction%")s=Yr("async function* () {}");else if(t==="%AsyncGenerator%"){var n=e("%AsyncGeneratorFunction%");n&&(s=n.prototype)}else if(t==="%AsyncIteratorPrototype%"){var a=e("%AsyncGenerator%");a&&H&&(s=H(a.prototype))}return fe[t]=s,s},So={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},et=he(),mt=zr(),yv=et.call(Xe,Array.prototype.concat),mv=et.call(Wo,Array.prototype.splice),Eo=et.call(Xe,String.prototype.replace),Rt=et.call(Xe,String.prototype.slice),Rv=et.call(Xe,RegExp.prototype.exec),qv=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,hv=/\\(\\)?/g,bv=function(t){var s=Rt(t,0,1),n=Rt(t,-1);if(s==="%"&&n!=="%")throw new De("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&s!=="%")throw new De("invalid intrinsic syntax, expected opening `%`");var a=[];return Eo(t,qv,function(o,i,p,u){a[a.length]=p?Eo(u,hv,"$1"):i||o}),a},fv=function(t,s){var n=t,a;if(mt(So,n)&&(a=So[n],n="%"+a[0]+"%"),mt(fe,n)){var o=fe[n];if(o===He&&(o=gv(n)),typeof o>"u"&&!s)throw new Qe("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:a,name:n,value:o}}throw new De("intrinsic "+t+" does not exist!")};_o.exports=function(t,s){if(typeof t!="string"||t.length===0)throw new Qe("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof s!="boolean")throw new Qe('"allowMissing" argument must be a boolean');if(Rv(/^%?[^%]*%?$/,t)===null)throw new De("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=bv(t),a=n.length>0?n[0]:"",o=fv("%"+a+"%",s),i=o.name,p=o.value,u=!1,r=o.alias;r&&(a=r[0],mv(n,yv([0,1],r)));for(var y=1,x=!0;y<n.length;y+=1){var m=n[y],k=Rt(m,0,1),P=Rt(m,-1);if((k==='"'||k==="'"||k==="`"||P==='"'||P==="'"||P==="`")&&k!==P)throw new De("property names with quotes must have matching quotes");if((m==="constructor"||!x)&&(u=!0),a+="."+m,i="%"+a+"%",mt(fe,i))p=fe[i];else if(p!=null){if(!(m in p)){if(!s)throw new Qe("base intrinsic for "+t+" exists, but the property is not available.");return}if(Ze&&y+1>=n.length){var q=Ze(p,m);x=!!q,x&&"get"in q&&!("originalValue"in q.get)?p=q.get:p=p[m]}else x=mt(p,m),p=p[m];x&&!u&&(fe[i]=p)}}return p}});var Fo=h((RB,Do)=>{"use strict";var Ho=Ge(),Iv=it(),Fe=qe(),Qo=Ue();Do.exports=function(t,s,n){if(!t||typeof t!="object"&&typeof t!="function")throw new Fe("`obj` must be an object or a function`");if(typeof s!="string"&&typeof s!="symbol")throw new Fe("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new Fe("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new Fe("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new Fe("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new Fe("`loose`, if provided, must be a boolean");var a=arguments.length>3?arguments[3]:null,o=arguments.length>4?arguments[4]:null,i=arguments.length>5?arguments[5]:null,p=arguments.length>6?arguments[6]:!1,u=!!Qo&&Qo(t,s);if(Ho)Ho(t,s,{configurable:i===null&&u?u.configurable:!i,enumerable:a===null&&u?u.enumerable:!a,value:n,writable:o===null&&u?u.writable:!o});else if(p||!a&&!o&&!i)t[s]=n;else throw new Iv("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")}});var Vo=h((qB,Oo)=>{"use strict";var Xr=Ge(),Mo=function(){return!!Xr};Mo.hasArrayLengthDefineBug=function(){if(!Xr)return null;try{return Xr([],"length",{value:1}).length!==1}catch{return!0}};Oo.exports=Mo});var Jo=h((hB,zo)=>{"use strict";var xv=qt(),No=Fo(),kv=Vo()(),Ko=Ue(),$o=qe(),Pv=xv("%Math.floor%");zo.exports=function(t,s){if(typeof t!="function")throw new $o("`fn` is not a function");if(typeof s!="number"||s<0||s>4294967295||Pv(s)!==s)throw new $o("`length` must be a positive 32-bit integer");var n=arguments.length>2&&!!arguments[2],a=!0,o=!0;if("length"in t&&Ko){var i=Ko(t,"length");i&&!i.configurable&&(a=!1),i&&!i.writable&&(o=!1)}return(a||o||!n)&&(kv?No(t,"length",s,!0,!0):No(t,"length",s)),t}});var ti=h((bB,ht)=>{"use strict";var es=he(),bt=qt(),vv=Jo(),Av=qe(),Zo=bt("%Function.prototype.apply%"),Xo=bt("%Function.prototype.call%"),ei=bt("%Reflect.apply%",!0)||es.call(Xo,Zo),jo=Ge(),Cv=bt("%Math.max%");ht.exports=function(t){if(typeof t!="function")throw new Av("a function is required");var s=ei(es,Xo,arguments);return vv(s,1+Cv(0,t.length-(arguments.length-1)),!0)};var Yo=function(){return ei(es,Zo,arguments)};jo?jo(ht.exports,"apply",{value:Yo}):ht.exports.apply=Yo});var ai=h((fB,ni)=>{"use strict";var ri=qt(),si=ti(),Bv=si(ri("String.prototype.indexOf"));ni.exports=function(t,s){var n=ri(t,!!s);return typeof n=="function"&&Bv(t,".prototype.")>-1?si(n):n}});var oi=h(()=>{});var Ci=h((kB,Ai)=>{var cs=typeof Map=="function"&&Map.prototype,ts=Object.getOwnPropertyDescriptor&&cs?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,It=cs&&ts&&typeof ts.get=="function"?ts.get:null,ii=cs&&Map.prototype.forEach,ds=typeof Set=="function"&&Set.prototype,rs=Object.getOwnPropertyDescriptor&&ds?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,xt=ds&&rs&&typeof rs.get=="function"?rs.get:null,pi=ds&&Set.prototype.forEach,Tv=typeof WeakMap=="function"&&WeakMap.prototype,rt=Tv?WeakMap.prototype.has:null,wv=typeof WeakSet=="function"&&WeakSet.prototype,st=wv?WeakSet.prototype.has:null,Uv=typeof WeakRef=="function"&&WeakRef.prototype,ui=Uv?WeakRef.prototype.deref:null,Gv=Boolean.prototype.valueOf,Sv=Object.prototype.toString,Ev=Function.prototype.toString,Lv=String.prototype.match,ls=String.prototype.slice,pe=String.prototype.replace,Wv=String.prototype.toUpperCase,ci=String.prototype.toLowerCase,bi=RegExp.prototype.test,di=Array.prototype.concat,Z=Array.prototype.join,_v=Array.prototype.slice,li=Math.floor,as=typeof BigInt=="function"?BigInt.prototype.valueOf:null,ss=Object.getOwnPropertySymbols,os=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,Me=typeof Symbol=="function"&&typeof Symbol.iterator=="object",O=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===Me||!0)?Symbol.toStringTag:null,fi=Object.prototype.propertyIsEnumerable,gi=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function yi(e,t){if(e===1/0||e===-1/0||e!==e||e&&e>-1e3&&e<1e3||bi.call(/e/,t))return t;var s=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof e=="number"){var n=e<0?-li(-e):li(e);if(n!==e){var a=String(n),o=ls.call(t,a.length+1);return pe.call(a,s,"$&_")+"."+pe.call(pe.call(o,/([0-9]{3})/g,"$&_"),/_$/,"")}}return pe.call(t,s,"$&_")}var is=oi(),mi=is.custom,Ri=ki(mi)?mi:null,Ii={__proto__:null,double:'"',single:"'"},Hv={__proto__:null,double:/(["\\])/g,single:/(['\\])/g};Ai.exports=function e(t,s,n,a){var o=s||{};if(re(o,"quoteStyle")&&!re(Ii,o.quoteStyle))throw new TypeError('option "quoteStyle" must be "single" or "double"');if(re(o,"maxStringLength")&&(typeof o.maxStringLength=="number"?o.maxStringLength<0&&o.maxStringLength!==1/0:o.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var i=re(o,"customInspect")?o.customInspect:!0;if(typeof i!="boolean"&&i!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(re(o,"indent")&&o.indent!==null&&o.indent!==" "&&!(parseInt(o.indent,10)===o.indent&&o.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(re(o,"numericSeparator")&&typeof o.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var p=o.numericSeparator;if(typeof t>"u")return"undefined";if(t===null)return"null";if(typeof t=="boolean")return t?"true":"false";if(typeof t=="string")return vi(t,o);if(typeof t=="number"){if(t===0)return 1/0/t>0?"0":"-0";var u=String(t);return p?yi(t,u):u}if(typeof t=="bigint"){var r=String(t)+"n";return p?yi(t,r):r}var y=typeof o.depth>"u"?5:o.depth;if(typeof n>"u"&&(n=0),n>=y&&y>0&&typeof t=="object")return ps(t)?"[Array]":"[Object]";var x=rA(o,n);if(typeof a>"u")a=[];else if(Pi(a,t)>=0)return"[Circular]";function m(Y,ae,ee){if(ae&&(a=_v.call(a),a.push(ae)),ee){var $e={depth:o.depth};return re(o,"quoteStyle")&&($e.quoteStyle=o.quoteStyle),e(Y,$e,n+1,a)}return e(Y,o,n+1,a)}if(typeof t=="function"&&!qi(t)){var k=$v(t),P=ft(t,m);return"[Function"+(k?": "+k:" (anonymous)")+"]"+(P.length>0?" { "+Z.call(P,", ")+" }":"")}if(ki(t)){var q=Me?pe.call(String(t),/^(Symbol\(.*\))_[^)]*$/,"$1"):os.call(t);return typeof t=="object"&&!Me?tt(q):q}if(Xv(t)){for(var L="<"+ci.call(String(t.nodeName)),I=t.attributes||[],K=0;K<I.length;K++)L+=" "+I[K].name+"="+xi(Qv(I[K].value),"double",o);return L+=">",t.childNodes&&t.childNodes.length&&(L+="..."),L+="</"+ci.call(String(t.nodeName))+">",L}if(ps(t)){if(t.length===0)return"[]";var J=ft(t,m);return x&&!tA(J)?"["+us(J,x)+"]":"[ "+Z.call(J,", ")+" ]"}if(Fv(t)){var j=ft(t,m);return!("cause"in Error.prototype)&&"cause"in t&&!fi.call(t,"cause")?"{ ["+String(t)+"] "+Z.call(di.call("[cause]: "+m(t.cause),j),", ")+" }":j.length===0?"["+String(t)+"]":"{ ["+String(t)+"] "+Z.call(j,", ")+" }"}if(typeof t=="object"&&i){if(Ri&&typeof t[Ri]=="function"&&is)return is(t,{depth:y-n});if(i!=="symbol"&&typeof t.inspect=="function")return t.inspect()}if(zv(t)){var ce=[];return ii&&ii.call(t,function(Y,ae){ce.push(m(ae,t,!0)+" => "+m(Y,t))}),hi("Map",It.call(t),ce,x)}if(Yv(t)){var Ne=[];return pi&&pi.call(t,function(Y){Ne.push(m(Y,t))}),hi("Set",xt.call(t),Ne,x)}if(Jv(t))return ns("WeakMap");if(Zv(t))return ns("WeakSet");if(jv(t))return ns("WeakRef");if(Ov(t))return tt(m(Number(t)));if(Nv(t))return tt(m(as.call(t)));if(Vv(t))return tt(Gv.call(t));if(Mv(t))return tt(m(String(t)));if(typeof window<"u"&&t===window)return"{ [object Window] }";if(typeof globalThis<"u"&&t===globalThis||typeof global<"u"&&t===global)return"{ [object globalThis] }";if(!Dv(t)&&!qi(t)){var de=ft(t,m),Ke=gi?gi(t)===Object.prototype:t instanceof Object||t.constructor===Object,ne=t instanceof Object?"":"null prototype",Ce=!Ke&&O&&Object(t)===t&&O in t?ls.call(ue(t),8,-1):ne?"Object":"",le=Ke||typeof t.constructor!="function"?"":t.constructor.name?t.constructor.name+" ":"",Be=le+(Ce||ne?"["+Z.call(di.call([],Ce||[],ne||[]),": ")+"] ":"");return de.length===0?Be+"{}":x?Be+"{"+us(de,x)+"}":Be+"{ "+Z.call(de,", ")+" }"}return String(t)};function xi(e,t,s){var n=s.quoteStyle||t,a=Ii[n];return a+e+a}function Qv(e){return pe.call(String(e),/"/g,"&quot;")}function ps(e){return ue(e)==="[object Array]"&&(!O||!(typeof e=="object"&&O in e))}function Dv(e){return ue(e)==="[object Date]"&&(!O||!(typeof e=="object"&&O in e))}function qi(e){return ue(e)==="[object RegExp]"&&(!O||!(typeof e=="object"&&O in e))}function Fv(e){return ue(e)==="[object Error]"&&(!O||!(typeof e=="object"&&O in e))}function Mv(e){return ue(e)==="[object String]"&&(!O||!(typeof e=="object"&&O in e))}function Ov(e){return ue(e)==="[object Number]"&&(!O||!(typeof e=="object"&&O in e))}function Vv(e){return ue(e)==="[object Boolean]"&&(!O||!(typeof e=="object"&&O in e))}function ki(e){if(Me)return e&&typeof e=="object"&&e instanceof Symbol;if(typeof e=="symbol")return!0;if(!e||typeof e!="object"||!os)return!1;try{return os.call(e),!0}catch{}return!1}function Nv(e){if(!e||typeof e!="object"||!as)return!1;try{return as.call(e),!0}catch{}return!1}var Kv=Object.prototype.hasOwnProperty||function(e){return e in this};function re(e,t){return Kv.call(e,t)}function ue(e){return Sv.call(e)}function $v(e){if(e.name)return e.name;var t=Lv.call(Ev.call(e),/^function\s*([\w$]+)/);return t?t[1]:null}function Pi(e,t){if(e.indexOf)return e.indexOf(t);for(var s=0,n=e.length;s<n;s++)if(e[s]===t)return s;return-1}function zv(e){if(!It||!e||typeof e!="object")return!1;try{It.call(e);try{xt.call(e)}catch{return!0}return e instanceof Map}catch{}return!1}function Jv(e){if(!rt||!e||typeof e!="object")return!1;try{rt.call(e,rt);try{st.call(e,st)}catch{return!0}return e instanceof WeakMap}catch{}return!1}function jv(e){if(!ui||!e||typeof e!="object")return!1;try{return ui.call(e),!0}catch{}return!1}function Yv(e){if(!xt||!e||typeof e!="object")return!1;try{xt.call(e);try{It.call(e)}catch{return!0}return e instanceof Set}catch{}return!1}function Zv(e){if(!st||!e||typeof e!="object")return!1;try{st.call(e,st);try{rt.call(e,rt)}catch{return!0}return e instanceof WeakSet}catch{}return!1}function Xv(e){return!e||typeof e!="object"?!1:typeof HTMLElement<"u"&&e instanceof HTMLElement?!0:typeof e.nodeName=="string"&&typeof e.getAttribute=="function"}function vi(e,t){if(e.length>t.maxStringLength){var s=e.length-t.maxStringLength,n="... "+s+" more character"+(s>1?"s":"");return vi(ls.call(e,0,t.maxStringLength),t)+n}var a=Hv[t.quoteStyle||"single"];a.lastIndex=0;var o=pe.call(pe.call(e,a,"\\$1"),/[\x00-\x1f]/g,eA);return xi(o,"single",t)}function eA(e){var t=e.charCodeAt(0),s={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return s?"\\"+s:"\\x"+(t<16?"0":"")+Wv.call(t.toString(16))}function tt(e){return"Object("+e+")"}function ns(e){return e+" { ? }"}function hi(e,t,s,n){var a=n?us(s,n):Z.call(s,", ");return e+" ("+t+") {"+a+"}"}function tA(e){for(var t=0;t<e.length;t++)if(Pi(e[t],`
2
+ `)>=0)return!1;return!0}function rA(e,t){var s;if(e.indent===" ")s=" ";else if(typeof e.indent=="number"&&e.indent>0)s=Z.call(Array(e.indent+1)," ");else return null;return{base:s,prev:Z.call(Array(t+1),s)}}function us(e,t){if(e.length===0)return"";var s=`
3
3
  `+t.prev+t.base;return s+Z.call(e,","+s)+`
4
- `+t.prev}function ft(e,t){var s=ps(e),n=[];if(s){n.length=e.length;for(var a=0;a<e.length;a++)n[a]=re(e,a)?t(e[a],e):""}var o=typeof ss=="function"?ss(e):[],i;if(Me){i={};for(var p=0;p<o.length;p++)i["$"+o[p]]=o[p]}for(var u in e)re(e,u)&&(s&&String(Number(u))===u&&u<e.length||Me&&i["$"+u]instanceof Symbol||(bi.call(/[^\w$]/,u)?n.push(t(u,e)+": "+t(e[u],e)):n.push(u+": "+t(e[u],e))));if(typeof ss=="function")for(var r=0;r<o.length;r++)fi.call(e,o[r])&&n.push("["+t(o[r])+"]: "+t(e[o[r]],e));return n}});var Ti=h((fB,Bi)=>{"use strict";var gs=Uo(),Oe=ai(),Xv=Ci(),eA=gs("%TypeError%"),kt=gs("%WeakMap%",!0),Pt=gs("%Map%",!0),tA=Oe("WeakMap.prototype.get",!0),rA=Oe("WeakMap.prototype.set",!0),sA=Oe("WeakMap.prototype.has",!0),nA=Oe("Map.prototype.get",!0),aA=Oe("Map.prototype.set",!0),oA=Oe("Map.prototype.has",!0),ys=function(e,t){for(var s=e,n;(n=s.next)!==null;s=n)if(n.key===t)return s.next=n.next,n.next=e.next,e.next=n,n},iA=function(e,t){var s=ys(e,t);return s&&s.value},pA=function(e,t,s){var n=ys(e,t);n?n.value=s:e.next={key:t,next:e.next,value:s}},uA=function(e,t){return!!ys(e,t)};Bi.exports=function(){var t,s,n,a={assert:function(o){if(!a.has(o))throw new eA("Side channel does not contain "+Xv(o))},get:function(o){if(kt&&o&&(typeof o=="object"||typeof o=="function")){if(t)return tA(t,o)}else if(Pt){if(s)return nA(s,o)}else if(n)return iA(n,o)},has:function(o){if(kt&&o&&(typeof o=="object"||typeof o=="function")){if(t)return sA(t,o)}else if(Pt){if(s)return oA(s,o)}else if(n)return uA(n,o);return!1},set:function(o,i){kt&&o&&(typeof o=="object"||typeof o=="function")?(t||(t=new kt),rA(t,o,i)):Pt?(s||(s=new Pt),aA(s,o,i)):(n||(n={key:{},next:null}),pA(n,o,i))}};return a}});var vt=h((IB,wi)=>{"use strict";var cA=String.prototype.replace,dA=/%20/g,ms={RFC1738:"RFC1738",RFC3986:"RFC3986"};wi.exports={default:ms.RFC3986,formatters:{RFC1738:function(e){return cA.call(e,dA,"+")},RFC3986:function(e){return String(e)}},RFC1738:ms.RFC1738,RFC3986:ms.RFC3986}});var qs=h((xB,Gi)=>{"use strict";var lA=vt(),Rs=Object.prototype.hasOwnProperty,Ie=Array.isArray,X=(function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e})(),gA=function(t){for(;t.length>1;){var s=t.pop(),n=s.obj[s.prop];if(Ie(n)){for(var a=[],o=0;o<n.length;++o)typeof n[o]<"u"&&a.push(n[o]);s.obj[s.prop]=a}}},Ui=function(t,s){for(var n=s&&s.plainObjects?Object.create(null):{},a=0;a<t.length;++a)typeof t[a]<"u"&&(n[a]=t[a]);return n},yA=function e(t,s,n){if(!s)return t;if(typeof s!="object"){if(Ie(t))t.push(s);else if(t&&typeof t=="object")(n&&(n.plainObjects||n.allowPrototypes)||!Rs.call(Object.prototype,s))&&(t[s]=!0);else return[t,s];return t}if(!t||typeof t!="object")return[t].concat(s);var a=t;return Ie(t)&&!Ie(s)&&(a=Ui(t,n)),Ie(t)&&Ie(s)?(s.forEach(function(o,i){if(Rs.call(t,i)){var p=t[i];p&&typeof p=="object"&&o&&typeof o=="object"?t[i]=e(p,o,n):t.push(o)}else t[i]=o}),t):Object.keys(s).reduce(function(o,i){var p=s[i];return Rs.call(o,i)?o[i]=e(o[i],p,n):o[i]=p,o},a)},mA=function(t,s){return Object.keys(s).reduce(function(n,a){return n[a]=s[a],n},t)},RA=function(e,t,s){var n=e.replace(/\+/g," ");if(s==="iso-8859-1")return n.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(n)}catch{return n}},qA=function(t,s,n,a,o){if(t.length===0)return t;var i=t;if(typeof t=="symbol"?i=Symbol.prototype.toString.call(t):typeof t!="string"&&(i=String(t)),n==="iso-8859-1")return escape(i).replace(/%u[0-9a-f]{4}/gi,function(y){return"%26%23"+parseInt(y.slice(2),16)+"%3B"});for(var p="",u=0;u<i.length;++u){var r=i.charCodeAt(u);if(r===45||r===46||r===95||r===126||r>=48&&r<=57||r>=65&&r<=90||r>=97&&r<=122||o===lA.RFC1738&&(r===40||r===41)){p+=i.charAt(u);continue}if(r<128){p=p+X[r];continue}if(r<2048){p=p+(X[192|r>>6]+X[128|r&63]);continue}if(r<55296||r>=57344){p=p+(X[224|r>>12]+X[128|r>>6&63]+X[128|r&63]);continue}u+=1,r=65536+((r&1023)<<10|i.charCodeAt(u)&1023),p+=X[240|r>>18]+X[128|r>>12&63]+X[128|r>>6&63]+X[128|r&63]}return p},hA=function(t){for(var s=[{obj:{o:t},prop:"o"}],n=[],a=0;a<s.length;++a)for(var o=s[a],i=o.obj[o.prop],p=Object.keys(i),u=0;u<p.length;++u){var r=p[u],y=i[r];typeof y=="object"&&y!==null&&n.indexOf(y)===-1&&(s.push({obj:i,prop:r}),n.push(y))}return gA(s),t},bA=function(t){return Object.prototype.toString.call(t)==="[object RegExp]"},fA=function(t){return!t||typeof t!="object"?!1:!!(t.constructor&&t.constructor.isBuffer&&t.constructor.isBuffer(t))},IA=function(t,s){return[].concat(t,s)},xA=function(t,s){if(Ie(t)){for(var n=[],a=0;a<t.length;a+=1)n.push(s(t[a]));return n}return s(t)};Gi.exports={arrayToObject:Ui,assign:mA,combine:IA,compact:hA,decode:RA,encode:qA,isBuffer:fA,isRegExp:bA,maybeMap:xA,merge:yA}});var Hi=h((kB,_i)=>{"use strict";var Li=Ti(),bs=qs(),nt=vt(),kA=Object.prototype.hasOwnProperty,Si={brackets:function(t){return t+"[]"},comma:"comma",indices:function(t,s){return t+"["+s+"]"},repeat:function(t){return t}},se=Array.isArray,PA=String.prototype.split,vA=Array.prototype.push,Wi=function(e,t){vA.apply(e,se(t)?t:[t])},AA=Date.prototype.toISOString,Ei=nt.default,F={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:bs.encode,encodeValuesOnly:!1,format:Ei,formatter:nt.formatters[Ei],indices:!1,serializeDate:function(t){return AA.call(t)},skipNulls:!1,strictNullHandling:!1},CA=function(t){return typeof t=="string"||typeof t=="number"||typeof t=="boolean"||typeof t=="symbol"||typeof t=="bigint"},hs={},BA=function e(t,s,n,a,o,i,p,u,r,y,x,m,k,P,q,L){for(var I=t,K=L,J=0,j=!1;(K=K.get(hs))!==void 0&&!j;){var ce=K.get(t);if(J+=1,typeof ce<"u"){if(ce===J)throw new RangeError("Cyclic object value");j=!0}typeof K.get(hs)>"u"&&(J=0)}if(typeof u=="function"?I=u(s,I):I instanceof Date?I=x(I):n==="comma"&&se(I)&&(I=bs.maybeMap(I,function(St){return St instanceof Date?x(St):St})),I===null){if(o)return p&&!P?p(s,F.encoder,q,"key",m):s;I=""}if(CA(I)||bs.isBuffer(I)){if(p){var Ne=P?s:p(s,F.encoder,q,"key",m);if(n==="comma"&&P){for(var de=PA.call(String(I),","),Ke="",ne=0;ne<de.length;++ne)Ke+=(ne===0?"":",")+k(p(de[ne],F.encoder,q,"value",m));return[k(Ne)+(a&&se(I)&&de.length===1?"[]":"")+"="+Ke]}return[k(Ne)+"="+k(p(I,F.encoder,q,"value",m))]}return[k(s)+"="+k(String(I))]}var Ce=[];if(typeof I>"u")return Ce;var le;if(n==="comma"&&se(I))le=[{value:I.length>0?I.join(",")||null:void 0}];else if(se(u))le=u;else{var Be=Object.keys(I);le=r?Be.sort(r):Be}for(var Y=a&&se(I)&&I.length===1?s+"[]":s,ae=0;ae<le.length;++ae){var ee=le[ae],$e=typeof ee=="object"&&typeof ee.value<"u"?ee.value:I[ee];if(!(i&&$e===null)){var ik=se(I)?typeof n=="function"?n(Y,ee):Y:Y+(y?"."+ee:"["+ee+"]");L.set(t,J);var ka=Li();ka.set(hs,L),Wi(Ce,e($e,ik,n,a,o,i,p,u,r,y,x,m,k,P,q,ka))}}return Ce},TA=function(t){if(!t)return F;if(t.encoder!==null&&typeof t.encoder<"u"&&typeof t.encoder!="function")throw new TypeError("Encoder has to be a function.");var s=t.charset||F.charset;if(typeof t.charset<"u"&&t.charset!=="utf-8"&&t.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var n=nt.default;if(typeof t.format<"u"){if(!kA.call(nt.formatters,t.format))throw new TypeError("Unknown format option provided.");n=t.format}var a=nt.formatters[n],o=F.filter;return(typeof t.filter=="function"||se(t.filter))&&(o=t.filter),{addQueryPrefix:typeof t.addQueryPrefix=="boolean"?t.addQueryPrefix:F.addQueryPrefix,allowDots:typeof t.allowDots>"u"?F.allowDots:!!t.allowDots,charset:s,charsetSentinel:typeof t.charsetSentinel=="boolean"?t.charsetSentinel:F.charsetSentinel,delimiter:typeof t.delimiter>"u"?F.delimiter:t.delimiter,encode:typeof t.encode=="boolean"?t.encode:F.encode,encoder:typeof t.encoder=="function"?t.encoder:F.encoder,encodeValuesOnly:typeof t.encodeValuesOnly=="boolean"?t.encodeValuesOnly:F.encodeValuesOnly,filter:o,format:n,formatter:a,serializeDate:typeof t.serializeDate=="function"?t.serializeDate:F.serializeDate,skipNulls:typeof t.skipNulls=="boolean"?t.skipNulls:F.skipNulls,sort:typeof t.sort=="function"?t.sort:null,strictNullHandling:typeof t.strictNullHandling=="boolean"?t.strictNullHandling:F.strictNullHandling}};_i.exports=function(e,t){var s=e,n=TA(t),a,o;typeof n.filter=="function"?(o=n.filter,s=o("",s)):se(n.filter)&&(o=n.filter,a=o);var i=[];if(typeof s!="object"||s===null)return"";var p;t&&t.arrayFormat in Si?p=t.arrayFormat:t&&"indices"in t?p=t.indices?"indices":"repeat":p="indices";var u=Si[p];if(t&&"commaRoundTrip"in t&&typeof t.commaRoundTrip!="boolean")throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var r=u==="comma"&&t&&t.commaRoundTrip;a||(a=Object.keys(s)),n.sort&&a.sort(n.sort);for(var y=Li(),x=0;x<a.length;++x){var m=a[x];n.skipNulls&&s[m]===null||Wi(i,BA(s[m],m,u,r,n.strictNullHandling,n.skipNulls,n.encode?n.encoder:null,n.filter,n.sort,n.allowDots,n.serializeDate,n.format,n.formatter,n.encodeValuesOnly,n.charset,y))}var k=i.join(n.delimiter),P=n.addQueryPrefix===!0?"?":"";return n.charsetSentinel&&(n.charset==="iso-8859-1"?P+="utf8=%26%2310003%3B&":P+="utf8=%E2%9C%93&"),k.length>0?P+k:""}});var Fi=h((PB,Di)=>{"use strict";var Ve=qs(),fs=Object.prototype.hasOwnProperty,wA=Array.isArray,Q={allowDots:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:Ve.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},UA=function(e){return e.replace(/&#(\d+);/g,function(t,s){return String.fromCharCode(parseInt(s,10))})},Qi=function(e,t){return e&&typeof e=="string"&&t.comma&&e.indexOf(",")>-1?e.split(","):e},GA="utf8=%26%2310003%3B",SA="utf8=%E2%9C%93",EA=function(t,s){var n={},a=s.ignoreQueryPrefix?t.replace(/^\?/,""):t,o=s.parameterLimit===1/0?void 0:s.parameterLimit,i=a.split(s.delimiter,o),p=-1,u,r=s.charset;if(s.charsetSentinel)for(u=0;u<i.length;++u)i[u].indexOf("utf8=")===0&&(i[u]===SA?r="utf-8":i[u]===GA&&(r="iso-8859-1"),p=u,u=i.length);for(u=0;u<i.length;++u)if(u!==p){var y=i[u],x=y.indexOf("]="),m=x===-1?y.indexOf("="):x+1,k,P;m===-1?(k=s.decoder(y,Q.decoder,r,"key"),P=s.strictNullHandling?null:""):(k=s.decoder(y.slice(0,m),Q.decoder,r,"key"),P=Ve.maybeMap(Qi(y.slice(m+1),s),function(q){return s.decoder(q,Q.decoder,r,"value")})),P&&s.interpretNumericEntities&&r==="iso-8859-1"&&(P=UA(P)),y.indexOf("[]=")>-1&&(P=wA(P)?[P]:P),fs.call(n,k)?n[k]=Ve.combine(n[k],P):n[k]=P}return n},LA=function(e,t,s,n){for(var a=n?t:Qi(t,s),o=e.length-1;o>=0;--o){var i,p=e[o];if(p==="[]"&&s.parseArrays)i=[].concat(a);else{i=s.plainObjects?Object.create(null):{};var u=p.charAt(0)==="["&&p.charAt(p.length-1)==="]"?p.slice(1,-1):p,r=parseInt(u,10);!s.parseArrays&&u===""?i={0:a}:!isNaN(r)&&p!==u&&String(r)===u&&r>=0&&s.parseArrays&&r<=s.arrayLimit?(i=[],i[r]=a):u!=="__proto__"&&(i[u]=a)}a=i}return a},WA=function(t,s,n,a){if(t){var o=n.allowDots?t.replace(/\.([^.[]+)/g,"[$1]"):t,i=/(\[[^[\]]*])/,p=/(\[[^[\]]*])/g,u=n.depth>0&&i.exec(o),r=u?o.slice(0,u.index):o,y=[];if(r){if(!n.plainObjects&&fs.call(Object.prototype,r)&&!n.allowPrototypes)return;y.push(r)}for(var x=0;n.depth>0&&(u=p.exec(o))!==null&&x<n.depth;){if(x+=1,!n.plainObjects&&fs.call(Object.prototype,u[1].slice(1,-1))&&!n.allowPrototypes)return;y.push(u[1])}return u&&y.push("["+o.slice(u.index)+"]"),LA(y,s,n,a)}},_A=function(t){if(!t)return Q;if(t.decoder!==null&&t.decoder!==void 0&&typeof t.decoder!="function")throw new TypeError("Decoder has to be a function.");if(typeof t.charset<"u"&&t.charset!=="utf-8"&&t.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var s=typeof t.charset>"u"?Q.charset:t.charset;return{allowDots:typeof t.allowDots>"u"?Q.allowDots:!!t.allowDots,allowPrototypes:typeof t.allowPrototypes=="boolean"?t.allowPrototypes:Q.allowPrototypes,allowSparse:typeof t.allowSparse=="boolean"?t.allowSparse:Q.allowSparse,arrayLimit:typeof t.arrayLimit=="number"?t.arrayLimit:Q.arrayLimit,charset:s,charsetSentinel:typeof t.charsetSentinel=="boolean"?t.charsetSentinel:Q.charsetSentinel,comma:typeof t.comma=="boolean"?t.comma:Q.comma,decoder:typeof t.decoder=="function"?t.decoder:Q.decoder,delimiter:typeof t.delimiter=="string"||Ve.isRegExp(t.delimiter)?t.delimiter:Q.delimiter,depth:typeof t.depth=="number"||t.depth===!1?+t.depth:Q.depth,ignoreQueryPrefix:t.ignoreQueryPrefix===!0,interpretNumericEntities:typeof t.interpretNumericEntities=="boolean"?t.interpretNumericEntities:Q.interpretNumericEntities,parameterLimit:typeof t.parameterLimit=="number"?t.parameterLimit:Q.parameterLimit,parseArrays:t.parseArrays!==!1,plainObjects:typeof t.plainObjects=="boolean"?t.plainObjects:Q.plainObjects,strictNullHandling:typeof t.strictNullHandling=="boolean"?t.strictNullHandling:Q.strictNullHandling}};Di.exports=function(e,t){var s=_A(t);if(e===""||e===null||typeof e>"u")return s.plainObjects?Object.create(null):{};for(var n=typeof e=="string"?EA(e,s):e,a=s.plainObjects?Object.create(null):{},o=Object.keys(n),i=0;i<o.length;++i){var p=o[i],u=WA(p,n[p],s,typeof e=="string");a=Ve.merge(a,u,s)}return s.allowSparse===!0?a:Ve.compact(a)}});var xe=h((vB,Mi)=>{"use strict";var HA=Hi(),QA=Fi(),DA=vt();Mi.exports={formats:DA,parse:QA,stringify:HA}});var W={};te(W,{HttpClient:()=>at,HttpError:()=>oe,createHttpClient:()=>qk,isHttpError:()=>ge,isNetworkError:()=>Rk,isNetworkOrIdempotentRequestError:()=>va});var yk=()=>typeof globalThis.crypto<"u"&&typeof globalThis.crypto.randomUUID=="function"?globalThis.crypto.randomUUID():Math.random().toString(36).substring(2,15),oe=class extends Error{constructor(s,n,a,o,i){super(s);this.config=n;this.code=a;this.response=o;this.name="HttpError",i!==void 0&&(this.cause=i)}isHttpError=!0},ge=e=>e instanceof oe||typeof e=="object"&&e!==null&&e.isHttpError===!0,mk=["get","head","options","put","delete"],Rk=e=>ge(e)&&!e.response,va=e=>{if(!ge(e))return!1;if(!e.response)return!0;let t=e.config.method?.toLowerCase()??"";return mk.includes(t)&&e.response.status>=500&&e.response.status<=599},qk=e=>new at({baseURL:e.apiUrl,headers:e.headers,withCredentials:e.withCredentials,timeout:e.timeout,debug:e.debug}),at=class{defaults;retry;constructor(t={}){this.defaults={headers:{},...t}}async request(t){let s=this.retry;if(!s?.retries)return this._requestOnce(t);for(let n=1;;n++)try{return await this._requestOnce(t)}catch(a){let o=t.signal?.aborted||this.defaults.signal?.aborted;if(!ge(a)||o||n>s.retries||!await(s.retryCondition??va)(a))throw a;let p=s.retryDelay?.(n,a)??0;p>0&&await new Promise(u=>setTimeout(u,p))}}get(t,s={}){return this.request({...s,method:"get",url:t})}delete(t,s={}){return this.request({...s,method:"delete",url:t})}post(t,s,n={}){return this.request({...n,method:"post",url:t,data:s})}put(t,s,n={}){return this.request({...n,method:"put",url:t,data:s})}async _requestOnce(t){let s=(t.method??"get").toUpperCase(),n=hk(t.baseURL??this.defaults.baseURL,t.url??""),a={...t,method:s,url:n},o=new Headers;Pa(o,this.defaults.headers),Pa(o,t.headers);let i;t.data!==void 0&&t.data!==null&&(bk(t.data)?i=t.data:(i=JSON.stringify(t.data),o.has("content-type")||o.set("content-type","application/json")));let p=t.timeout??this.defaults.timeout,u=[];t.signal&&u.push(t.signal),this.defaults.signal&&u.push(this.defaults.signal);let r=!1,y;if(p&&p>0&&Number.isFinite(p)){let q=new AbortController;y=setTimeout(()=>{r=!0,q.abort()},p),u.push(q.signal)}let x=this.defaults.debug??!1,m=x?yk():void 0,k=Date.now();x&&console.debug(kk(a,o,m));let P=q=>{if(r)return new oe(`timeout of ${p}ms exceeded`,a,"ECONNABORTED",void 0,q);if(t.signal?.aborted||this.defaults.signal?.aborted)return new oe("canceled",a,"ERR_CANCELED",void 0,q);let L=q?.cause,I=q?.message??"Network Error";return new oe(I,a,L?.code??"ERR_NETWORK",void 0,q)};try{let q=await fetch(n,{method:s,headers:o,body:i,signal:Ik(u),credentials:t.withCredentials??this.defaults.withCredentials?"include":void 0}),L={};q.headers.forEach((j,ce)=>{L[ce]=j});let I,K=t.responseType??"json";if(!q.ok||K==="json"||K==="text"){let j=await q.text();I=!q.ok||K==="json"?fk(j):j}else K==="arraybuffer"?I=await q.arrayBuffer():I=q.body?xk(q.body):void 0;let J={data:I,status:q.status,statusText:q.statusText,headers:L,config:a};if(x&&console.debug(Pk(J,m,k)),!q.ok)throw new oe(`Request failed with status code ${q.status}`,a,void 0,J);return J}catch(q){let L=ge(q)?q:P(q);throw x&&!L.response&&console.debug(vk(L,m,k)),L}finally{y!==void 0&&clearTimeout(y)}}},hk=(e,t)=>!e||/^https?:\/\//i.test(t)?t:t?`${e.replace(/\/+$/,"")}/${t.replace(/^\/+/,"")}`:e,Pa=(e,t)=>{for(let[s,n]of Object.entries(t??{})){if(n===void 0){e.delete(s);continue}if(Array.isArray(n)){e.delete(s);for(let a of n)e.append(s,a)}else e.set(s,n)}},bk=e=>typeof e=="string"||e instanceof Uint8Array||e instanceof ArrayBuffer||typeof Blob<"u"&&e instanceof Blob||typeof FormData<"u"&&e instanceof FormData||typeof URLSearchParams<"u"&&e instanceof URLSearchParams,fk=e=>{if(e)try{return JSON.parse(e)}catch{return e}},Ik=e=>{if(e.length===0)return;if(e.length===1)return e[0];if(typeof AbortSignal.any=="function")return AbortSignal.any(e);let t=new AbortController;for(let s of e){if(s.aborted){t.abort(s.reason);break}s.addEventListener("abort",()=>t.abort(s.reason),{once:!0})}return t.signal};async function*xk(e){let t=e.getReader();try{for(;;){let{done:s,value:n}=await t.read();if(s)break;n&&(yield n)}}finally{t.releaseLock()}}var kk=(e,t,s)=>{let n={};return t.forEach((a,o)=>{n[o]=a}),"REQUEST: "+JSON.stringify({method:e.method?.toUpperCase(),url:e.url,timestamp:new Date().toISOString(),requestId:s,headers:n,body:e.data})+`
5
- `},Pk=(e,t,s)=>"RESPONSE: "+JSON.stringify({method:e.config.method?.toUpperCase(),status:e.status,url:e.config.url,timestamp:new Date().toISOString(),requestId:t,duration:`${Date.now()-s}ms`,headers:e.headers,body:e.data})+`
6
- `,vk=(e,t,s)=>"ERROR: "+JSON.stringify({status:e.code,url:e.config.url,timestamp:new Date().toISOString(),requestId:t??"N/A",duration:`${Date.now()-s}ms`});var Bu={};te(Bu,{Client:()=>Is});var $={};te($,{getClientConfig:()=>Lk});import{isBrowser as Aa,isNode as Ak}from"browser-or-node";var Ck="https://api.botpress.cloud",Bk=6e4,Tk=!1,wk="BP_API_URL",Uk="BP_BOT_ID",Gk="BP_INTEGRATION_ID",Sk="BP_WORKSPACE_ID",Ek="BP_TOKEN";function Lk(e){let t=Wk(e),s={};t.workspaceId&&(s["x-workspace-id"]=t.workspaceId),t.botId&&(s["x-bot-id"]=t.botId),t.integrationId&&(s["x-integration-id"]=t.integrationId),t.integrationAlias&&(s["x-integration-alias"]=t.integrationAlias),t.token&&(s.Authorization=`Bearer ${t.token}`),s={...s,...t.headers};let n=t.apiUrl??Ck,a=t.timeout??Bk,o=t.debug??Tk;return{apiUrl:n,timeout:a,withCredentials:Aa,headers:s,debug:o}}function Wk(e){return Aa?e:Ak?_k(e):e}function _k(e){let t={...e,apiUrl:e.apiUrl??process.env[wk],botId:e.botId??process.env[Uk],integrationId:e.integrationId??process.env[Gk],integrationAlias:e.integrationAlias,workspaceId:e.workspaceId??process.env[Sk]},s=t.token??process.env[Ek];return s&&(t.token=s),t}var R={};te(R,{AsyncCollection:()=>Lt});var Lt=class{constructor(t){this._list=t}async*[Symbol.asyncIterator](){let t;do{let{items:s,meta:n}=await this._list({nextToken:t});t=n.nextToken;for(let a of s)yield a}while(t)}async collect(t={}){let s=t.limit??Number.POSITIVE_INFINITY,n=[],a=0;for await(let o of this)if(n.push(o),a++,a>=s)break;return n}};var z={};te(z,{toApiError:()=>Vk});var Hk={getRandomValues:e=>new Uint8Array(e.map(()=>Math.floor(Math.random()*256)))},Qk=typeof globalThis.crypto<"u"&&typeof globalThis.crypto.getRandomValues=="function"?globalThis.crypto:Hk,B=class e extends Error{constructor(s,n,a,o,i,p,u){super(o);this.code=s;this.description=n;this.type=a;this.message=o;this.error=i;this.id=p;this.metadata=u;this.id||(this.id=e.generateId())}isApiError=!0;format(){return`[${this.type}] ${this.message} (Error ID: ${this.id})`}toJSON(){return{id:this.id,code:this.code,type:this.type,message:this.message,metadata:this.metadata}}static generateId(){let s=this.getPrefix(),n=new Date().toISOString().replace(/[\-:TZ]/g,"").split(".")[0],a=4,o=Array.from(Qk.getRandomValues(new Uint8Array(a))).map(i=>i.toString(16).padStart(2,"0")).join("").toUpperCase();return`${s}_${n}x${o}`}static getPrefix(){return typeof window<"u"&&typeof window.document<"u"?"err_bwsr":"err"}},Dk=e=>typeof e=="object"&&!Array.isArray(e)&&e!==null,Fk=e=>e instanceof B||Dk(e)&&e.isApiError===!0,ye=class extends B{constructor(t,s,n,a){super(500,"An unknown error occurred","Unknown",t,s,n,a)}},Wt=class extends B{constructor(t,s,n,a){super(500,"An internal error occurred","Internal",t,s,n,a)}},_t=class extends B{constructor(t,s,n,a){super(401,"The request requires to be authenticated.","Unauthorized",t,s,n,a)}},Ht=class extends B{constructor(t,s,n,a){super(403,"The requested action can't be peform by this resource.","Forbidden",t,s,n,a)}},Qt=class extends B{constructor(t,s,n,a){super(413,"The request payload is too large.","PayloadTooLarge",t,s,n,a)}},Dt=class extends B{constructor(t,s,n,a){super(400,"The request payload is invalid.","InvalidPayload",t,s,n,a)}},Ft=class extends B{constructor(t,s,n,a){super(415,"The request is invalid because the content-type is not supported.","UnsupportedMediaType",t,s,n,a)}},Mt=class extends B{constructor(t,s,n,a){super(405,"The requested method does not exist.","MethodNotFound",t,s,n,a)}},Ot=class extends B{constructor(t,s,n,a){super(404,"The requested resource does not exist.","ResourceNotFound",t,s,n,a)}},Vt=class extends B{constructor(t,s,n,a){super(400,"The provided JSON schema is invalid.","InvalidJsonSchema",t,s,n,a)}},Nt=class extends B{constructor(t,s,n,a){super(400,"The provided data doesn't respect the provided JSON schema.","InvalidDataFormat",t,s,n,a)}},Kt=class extends B{constructor(t,s,n,a){super(400,"The provided identifier is not valid. An identifier must start with a lowercase letter, be between 2 and 100 characters long and use only alphanumeric characters.","InvalidIdentifier",t,s,n,a)}},$t=class extends B{constructor(t,s,n,a){super(409,"The resource is related with a different resource that the one referenced in the request. This is usually caused when providing two resource identifiers that aren't linked together.","RelationConflict",t,s,n,a)}},zt=class extends B{constructor(t,s,n,a){super(409,"The resource cannot be deleted because it's referenced by another resource","ReferenceConstraint",t,s,n,a)}},Jt=class extends B{constructor(t,s,n,a){super(409,"The resource is current locked and cannot be operated on until the lock is released.","ResourceLockedConflict",t,s,n,a)}},jt=class extends B{constructor(t,s,n,a){super(410,"The requested resource is no longer available.","ResourceGone",t,s,n,a)}},Yt=class extends B{constructor(t,s,n,a){super(400,"The provided resource reference is missing. This is usually caused when providing an invalid id inside the payload of a request.","ReferenceNotFound",t,s,n,a)}},Zt=class extends B{constructor(t,s,n,a){super(400,"The provided query is invalid. This is usually caused when providing an invalid parameter for querying a resource.","InvalidQuery",t,s,n,a)}},Xt=class extends B{constructor(t,s,n,a){super(400,"An error happened during the execution of a runtime (bot or integration).","Runtime",t,s,n,a)}},er=class extends B{constructor(t,s,n,a){super(409,"The record attempted to be created already exists.","AlreadyExists",t,s,n,a)}},tr=class extends B{constructor(t,s,n,a){super(429,"The request has been rate limited.","RateLimited",t,s,n,a)}},rr=class extends B{constructor(t,s,n,a){super(402,"A payment is required to perform this request.","PaymentRequired",t,s,n,a)}},sr=class extends B{constructor(t,s,n,a){super(403,"The request exceeds the allowed quota. Quotas are a soft limit that can be increased.","QuotaExceeded",t,s,n,a)}},nr=class extends B{constructor(t,s,n,a){super(413,"The request exceeds the allowed limit. Limits are a hard limit that cannot be increased.","LimitExceeded",t,s,n,a)}},ar=class extends B{constructor(t,s,n,a){super(400,"Request payload contains breaking changes which is not allowed for this resource without a version increment.","BreakingChanges",t,s,n,a)}},or=class extends B{constructor(t,s,n,a){super(504,"The operation timed out.","OperationTimeout",t,s,n,a)}},Mk={Unknown:ye,Internal:Wt,Unauthorized:_t,Forbidden:Ht,PayloadTooLarge:Qt,InvalidPayload:Dt,UnsupportedMediaType:Ft,MethodNotFound:Mt,ResourceNotFound:Ot,InvalidJsonSchema:Vt,InvalidDataFormat:Nt,InvalidIdentifier:Kt,RelationConflict:$t,ReferenceConstraint:zt,ResourceLockedConflict:Jt,ResourceGone:jt,ReferenceNotFound:Yt,InvalidQuery:Zt,Runtime:Xt,AlreadyExists:er,RateLimited:tr,PaymentRequired:rr,QuotaExceeded:sr,LimitExceeded:nr,BreakingChanges:ar,OperationTimeout:or},we=e=>Fk(e)?e:e instanceof Error?new ye(e.message,e):typeof e=="string"?new ye(e):Ok(e);function Ok(e){if(typeof e=="object"&&"code"in e&&"type"in e&&"id"in e&&"message"in e&&typeof e.type=="string"&&typeof e.message=="string"){let t=Mk[e.type];return t?new t(e.message,void 0,e.id||"UNKNOWN",e.metadata):new ye(`An unclassified API error occurred: ${e.message} (Type: ${e.type}, Code: ${e.code})`)}return new ye("An invalid error occurred: "+JSON.stringify(e))}var ie=class extends Error{constructor(s,n,a){super(s);this.innerError=n;this.file=a;this.name="FileUploadError"}};var Vk=e=>ge(e)&&e.response?.data?we(e.response.data):we(e);var Nk={getRandomValues:e=>new Uint8Array(e.map(()=>Math.floor(Math.random()*256)))},Kk=typeof globalThis.crypto<"u"&&typeof globalThis.crypto.getRandomValues=="function"?globalThis.crypto:Nk,T=class e extends Error{constructor(s,n,a,o,i,p,u){super(o);this.code=s;this.description=n;this.type=a;this.message=o;this.error=i;this.id=p;this.metadata=u;this.id||(this.id=e.generateId())}isApiError=!0;format(){return`[${this.type}] ${this.message} (Error ID: ${this.id})`}toJSON(){return{id:this.id,code:this.code,type:this.type,message:this.message,metadata:this.metadata}}static generateId(){let s=this.getPrefix(),n=new Date().toISOString().replace(/[\-:TZ]/g,"").split(".")[0],a=4,o=Array.from(Kk.getRandomValues(new Uint8Array(a))).map(i=>i.toString(16).padStart(2,"0")).join("").toUpperCase();return`${s}_${n}x${o}`}static getPrefix(){return typeof window<"u"&&typeof window.document<"u"?"err_bwsr":"err"}},$k=e=>typeof e=="object"&&!Array.isArray(e)&&e!==null,zk=e=>e instanceof T||$k(e)&&e.isApiError===!0,Re=class extends T{constructor(t,s,n,a){super(500,"An unknown error occurred","Unknown",t,s,n,a)}},ir=class extends T{constructor(t,s,n,a){super(500,"An internal error occurred","Internal",t,s,n,a)}},pr=class extends T{constructor(t,s,n,a){super(401,"The request requires to be authenticated.","Unauthorized",t,s,n,a)}},ur=class extends T{constructor(t,s,n,a){super(403,"The requested action can't be peform by this resource.","Forbidden",t,s,n,a)}},cr=class extends T{constructor(t,s,n,a){super(413,"The request payload is too large.","PayloadTooLarge",t,s,n,a)}},dr=class extends T{constructor(t,s,n,a){super(400,"The request payload is invalid.","InvalidPayload",t,s,n,a)}},lr=class extends T{constructor(t,s,n,a){super(415,"The request is invalid because the content-type is not supported.","UnsupportedMediaType",t,s,n,a)}},gr=class extends T{constructor(t,s,n,a){super(405,"The requested method does not exist.","MethodNotFound",t,s,n,a)}},yr=class extends T{constructor(t,s,n,a){super(404,"The requested resource does not exist.","ResourceNotFound",t,s,n,a)}},mr=class extends T{constructor(t,s,n,a){super(400,"The provided JSON schema is invalid.","InvalidJsonSchema",t,s,n,a)}},Rr=class extends T{constructor(t,s,n,a){super(400,"The provided data doesn't respect the provided JSON schema.","InvalidDataFormat",t,s,n,a)}},qr=class extends T{constructor(t,s,n,a){super(400,"The provided identifier is not valid. An identifier must start with a lowercase letter, be between 2 and 100 characters long and use only alphanumeric characters.","InvalidIdentifier",t,s,n,a)}},hr=class extends T{constructor(t,s,n,a){super(409,"The resource is related with a different resource that the one referenced in the request. This is usually caused when providing two resource identifiers that aren't linked together.","RelationConflict",t,s,n,a)}},br=class extends T{constructor(t,s,n,a){super(409,"The resource cannot be deleted because it's referenced by another resource","ReferenceConstraint",t,s,n,a)}},fr=class extends T{constructor(t,s,n,a){super(409,"The resource is current locked and cannot be operated on until the lock is released.","ResourceLockedConflict",t,s,n,a)}},Ir=class extends T{constructor(t,s,n,a){super(410,"The requested resource is no longer available.","ResourceGone",t,s,n,a)}},xr=class extends T{constructor(t,s,n,a){super(400,"The provided resource reference is missing. This is usually caused when providing an invalid id inside the payload of a request.","ReferenceNotFound",t,s,n,a)}},kr=class extends T{constructor(t,s,n,a){super(400,"The provided query is invalid. This is usually caused when providing an invalid parameter for querying a resource.","InvalidQuery",t,s,n,a)}},Pr=class extends T{constructor(t,s,n,a){super(400,"An error happened during the execution of a runtime (bot or integration).","Runtime",t,s,n,a)}},vr=class extends T{constructor(t,s,n,a){super(409,"The record attempted to be created already exists.","AlreadyExists",t,s,n,a)}},Ar=class extends T{constructor(t,s,n,a){super(429,"The request has been rate limited.","RateLimited",t,s,n,a)}},Cr=class extends T{constructor(t,s,n,a){super(402,"A payment is required to perform this request.","PaymentRequired",t,s,n,a)}},Br=class extends T{constructor(t,s,n,a){super(403,"The request exceeds the allowed quota. Quotas are a soft limit that can be increased.","QuotaExceeded",t,s,n,a)}},Tr=class extends T{constructor(t,s,n,a){super(413,"The request exceeds the allowed limit. Limits are a hard limit that cannot be increased.","LimitExceeded",t,s,n,a)}},wr=class extends T{constructor(t,s,n,a){super(400,"Request payload contains breaking changes which is not allowed for this resource without a version increment.","BreakingChanges",t,s,n,a)}},Ur=class extends T{constructor(t,s,n,a){super(504,"The operation timed out.","OperationTimeout",t,s,n,a)}},Jk={Unknown:Re,Internal:ir,Unauthorized:pr,Forbidden:ur,PayloadTooLarge:cr,InvalidPayload:dr,UnsupportedMediaType:lr,MethodNotFound:gr,ResourceNotFound:yr,InvalidJsonSchema:mr,InvalidDataFormat:Rr,InvalidIdentifier:qr,RelationConflict:hr,ReferenceConstraint:br,ResourceLockedConflict:fr,ResourceGone:Ir,ReferenceNotFound:xr,InvalidQuery:kr,Runtime:Pr,AlreadyExists:vr,RateLimited:Ar,PaymentRequired:Cr,QuotaExceeded:Br,LimitExceeded:Tr,BreakingChanges:wr,OperationTimeout:Ur},Gr=e=>zk(e)?e:e instanceof Error?new Re(e.message,e):typeof e=="string"?new Re(e):jk(e);function jk(e){if(typeof e=="object"&&"code"in e&&"type"in e&&"id"in e&&"message"in e&&typeof e.type=="string"&&typeof e.message=="string"){let t=Jk[e.type];return t?new t(e.message,void 0,e.id||"UNKNOWN",e.metadata):new Re(`An unclassified API error occurred: ${e.message} (Type: ${e.type}, Code: ${e.code})`)}return new Re("An invalid error occurred: "+JSON.stringify(e))}var Oi=Te(xe()),FA=e=>e[1]!==void 0,b=e=>{let{method:t,path:s,query:n,headers:a,body:o}=e,i=Object.entries(a).filter(FA),p=Object.fromEntries(i),u=Oi.default.stringify(n,{encode:!0,arrayFormat:"repeat",allowDots:!0}),r=u?[s,u].join("?"):s,y=["put","post","delete","patch"].includes(t.toLowerCase())?o:void 0;return{method:t,url:r,headers:p,data:y}};var Vi=e=>({path:"/v1/chat/conversations",headers:{},query:{},params:{},body:{channel:e.channel,tags:e.tags,integrationName:e.integrationName,properties:e.properties}});var Ki=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var zi=e=>({path:"/v1/chat/conversations",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,sortField:e.sortField,sortDirection:e.sortDirection,tags:e.tags,participantIds:e.participantIds,integrationName:e.integrationName,channel:e.channel,afterDate:e.afterDate,beforeDate:e.beforeDate,minMessageCount:e.minMessageCount,maxMessageCount:e.maxMessageCount},params:{},body:{}});var ji=e=>({path:"/v1/chat/conversations/get-or-create",headers:{},query:{},params:{},body:{channel:e.channel,tags:e.tags,integrationName:e.integrationName,properties:e.properties,discriminateByTags:e.discriminateByTags}});var Zi=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{currentTaskId:e.currentTaskId,tags:e.tags,properties:e.properties}});var ep=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var rp=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var np=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants`,headers:{},query:{},params:{id:e.id},body:{userId:e.userId}});var op=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants/${encodeURIComponent(e.userId)}`,headers:{},query:{},params:{id:e.id,userId:e.userId},body:{}});var pp=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants/${encodeURIComponent(e.userId)}`,headers:{},query:{},params:{id:e.id,userId:e.userId},body:{}});var cp=e=>({path:"/v1/chat/events",headers:{},query:{},params:{},body:{type:e.type,payload:e.payload,schedule:e.schedule,conversationId:e.conversationId,userId:e.userId,workflowId:e.workflowId,messageId:e.messageId}});var lp=e=>({path:`/v1/chat/events/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var yp=e=>({path:"/v1/chat/events",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,type:e.type,conversationId:e.conversationId,userId:e.userId,messageId:e.messageId,workflowId:e.workflowId,status:e.status},params:{},body:{}});var Rp=e=>({path:`/v1/chat/events/scheduled/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var hp=e=>({path:"/v1/chat/messages",headers:{},query:{},params:{},body:{payload:e.payload,userId:e.userId,conversationId:e.conversationId,type:e.type,tags:e.tags,schedule:e.schedule,origin:e.origin}});var fp=e=>({path:"/v1/chat/messages/get-or-create",headers:{},query:{},params:{},body:{payload:e.payload,userId:e.userId,conversationId:e.conversationId,type:e.type,tags:e.tags,schedule:e.schedule,origin:e.origin,discriminateByTags:e.discriminateByTags}});var xp=e=>({path:`/v1/chat/messages/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Pp=e=>({path:`/v1/chat/messages/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{tags:e.tags,payload:e.payload}});var Ap=e=>({path:"/v1/chat/messages",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,conversationId:e.conversationId,tags:e.tags,afterDate:e.afterDate,beforeDate:e.beforeDate},params:{},body:{}});var Bp=e=>({path:`/v1/chat/messages/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var wp=e=>({path:"/v1/chat/initialize-incoming-message",headers:{},query:{},params:{},body:{userId:e.userId,user:e.user,conversationId:e.conversationId,conversation:e.conversation,message:e.message}});var Gp=e=>({path:"/v1/chat/messages/import-messages",headers:{},query:{},params:{},body:{messages:e.messages}});var Ep=e=>({path:"/v1/chat/users",headers:{},query:{},params:{},body:{tags:e.tags,integrationName:e.integrationName,name:e.name,pictureUrl:e.pictureUrl,properties:e.properties,attributes:e.attributes}});var Wp=e=>({path:`/v1/chat/users/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Hp=e=>({path:"/v1/chat/users",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,conversationId:e.conversationId,tags:e.tags,afterDate:e.afterDate,beforeDate:e.beforeDate,rangeField:e.rangeField,sortField:e.sortField,sortDirection:e.sortDirection},params:{},body:{}});var Dp=e=>({path:"/v1/chat/users/get-or-create",headers:{},query:{},params:{},body:{tags:e.tags,integrationName:e.integrationName,name:e.name,pictureUrl:e.pictureUrl,properties:e.properties,attributes:e.attributes,discriminateByTags:e.discriminateByTags}});var Mp=e=>({path:`/v1/chat/users/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{tags:e.tags,name:e.name,pictureUrl:e.pictureUrl,attributes:e.attributes,properties:e.properties}});var Vp=e=>({path:`/v1/chat/users/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Kp=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}/expiry`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{expiry:e.expiry}});var zp=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{}});var jp=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{payload:e.payload,expiry:e.expiry}});var Zp=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}/get-or-set`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{payload:e.payload,expiry:e.expiry}});var eu=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{payload:e.payload,expiry:e.expiry}});var ru=e=>({path:"/v1/chat/actions",headers:{},query:{},params:{},body:{type:e.type,input:e.input}});var nu=e=>({path:"/v1/chat/integration/identifiers",headers:{},query:{value:e.value},params:{},body:{}});var ou=e=>({path:"/v1/chat/integration/identifiers/availability",headers:{},query:{value:e.value},params:{},body:{}});var pu=e=>({path:"/v1/chat/integrations/configure",headers:{},query:{},params:{},body:{identifier:e.identifier,scheduleRegisterCall:e.scheduleRegisterCall,sandboxIdentifiers:e.sandboxIdentifiers}});var cu=e=>({path:"/v1/chat/workflows",headers:{},query:{},params:{},body:{name:e.name,input:e.input,parentWorkflowId:e.parentWorkflowId,conversationId:e.conversationId,userId:e.userId,timeoutAt:e.timeoutAt,tags:e.tags,status:e.status,eventId:e.eventId}});var lu=e=>({path:`/v1/chat/workflows/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var yu=e=>({path:`/v1/chat/workflows/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{output:e.output,timeoutAt:e.timeoutAt,status:e.status,failureReason:e.failureReason,tags:e.tags,userId:e.userId,eventId:e.eventId}});var Ru=e=>({path:`/v1/chat/workflows/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var hu=e=>({path:"/v1/chat/workflows",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,tags:e.tags,conversationId:e.conversationId,userId:e.userId,parentWorkflowId:e.parentWorkflowId,statuses:e.statuses,name:e.name},params:{},body:{}});var fu=e=>({path:"/v1/chat/workflows/get-or-create",headers:{},query:{},params:{},body:{name:e.name,input:e.input,parentWorkflowId:e.parentWorkflowId,conversationId:e.conversationId,userId:e.userId,timeoutAt:e.timeoutAt,tags:e.tags,status:e.status,eventId:e.eventId,discriminateByTags:e.discriminateByTags,discriminateByStatusGroup:e.discriminateByStatusGroup}});var xu=e=>({path:`/v1/chat/tags/${encodeURIComponent(e.key)}/values`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,type:e.type},params:{key:e.key},body:{}});var Pu=e=>({path:"/v1/chat/analytics",headers:{},query:{},params:{},body:{name:e.name,count:e.count}});var Au=e=>({path:"/v1/chat/observations",headers:{},query:{},params:{},body:{id:e.id,name:e.name,data:e.data,messageId:e.messageId,eventId:e.eventId,conversationId:e.conversationId,userId:e.userId,errorId:e.errorId,traceId:e.traceId}});var At=class{constructor(t,s={}){this.httpClient=t;this.props=s}createConversation=async t=>{let{path:s,headers:n,query:a,body:o}=Vi(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getConversation=async t=>{let{path:s,headers:n,query:a,body:o}=Ki(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listConversations=async t=>{let{path:s,headers:n,query:a,body:o}=zi(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateConversation=async t=>{let{path:s,headers:n,query:a,body:o}=ji(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateConversation=async t=>{let{path:s,headers:n,query:a,body:o}=Zi(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteConversation=async t=>{let{path:s,headers:n,query:a,body:o}=ep(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listParticipants=async t=>{let{path:s,headers:n,query:a,body:o}=rp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};addParticipant=async t=>{let{path:s,headers:n,query:a,body:o}=np(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getParticipant=async t=>{let{path:s,headers:n,query:a,body:o}=op(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};removeParticipant=async t=>{let{path:s,headers:n,query:a,body:o}=pp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createEvent=async t=>{let{path:s,headers:n,query:a,body:o}=cp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getEvent=async t=>{let{path:s,headers:n,query:a,body:o}=lp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listEvents=async t=>{let{path:s,headers:n,query:a,body:o}=yp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};cancelScheduledEvent=async t=>{let{path:s,headers:n,query:a,body:o}=Rp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createMessage=async t=>{let{path:s,headers:n,query:a,body:o}=hp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateMessage=async t=>{let{path:s,headers:n,query:a,body:o}=fp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getMessage=async t=>{let{path:s,headers:n,query:a,body:o}=xp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateMessage=async t=>{let{path:s,headers:n,query:a,body:o}=Pp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listMessages=async t=>{let{path:s,headers:n,query:a,body:o}=Ap(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteMessage=async t=>{let{path:s,headers:n,query:a,body:o}=Bp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};initializeIncomingMessage=async t=>{let{path:s,headers:n,query:a,body:o}=wp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};importMessages=async t=>{let{path:s,headers:n,query:a,body:o}=Gp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createUser=async t=>{let{path:s,headers:n,query:a,body:o}=Ep(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getUser=async t=>{let{path:s,headers:n,query:a,body:o}=Wp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsers=async t=>{let{path:s,headers:n,query:a,body:o}=Hp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateUser=async t=>{let{path:s,headers:n,query:a,body:o}=Dp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateUser=async t=>{let{path:s,headers:n,query:a,body:o}=Mp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteUser=async t=>{let{path:s,headers:n,query:a,body:o}=Vp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setStateExpiry=async t=>{let{path:s,headers:n,query:a,body:o}=Kp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getState=async t=>{let{path:s,headers:n,query:a,body:o}=zp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setState=async t=>{let{path:s,headers:n,query:a,body:o}=jp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrSetState=async t=>{let{path:s,headers:n,query:a,body:o}=Zp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};patchState=async t=>{let{path:s,headers:n,query:a,body:o}=eu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"patch",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};callAction=async t=>{let{path:s,headers:n,query:a,body:o}=ru(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};unlinkIntegrationIdentifier=async t=>{let{path:s,headers:n,query:a,body:o}=nu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationIdentifierAvailability=async t=>{let{path:s,headers:n,query:a,body:o}=ou(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};configureIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=pu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=cu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=lu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=yu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=Ru(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkflows=async t=>{let{path:s,headers:n,query:a,body:o}=hu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=fu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listTagValues=async t=>{let{path:s,headers:n,query:a,body:o}=xu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};trackAnalytics=async t=>{let{path:s,headers:n,query:a,body:o}=Pu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};captureObservation=async t=>{let{path:s,headers:n,query:a,body:o}=Au(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})}};function f(e){let t=e?.response?.data;return t?Gr(t):Gr(e)}var Is=class extends At{config;constructor(t){let s=$.getClientConfig(t),n=W.createHttpClient(s);super(n,{toApiError:z.toApiError}),t.retry&&(n.retry=t.retry),this.config=s}get list(){return{conversations:t=>new R.AsyncCollection(({nextToken:s})=>this.listConversations({nextToken:s,...t}).then(n=>({...n,items:n.conversations}))),participants:t=>new R.AsyncCollection(({nextToken:s})=>this.listParticipants({nextToken:s,...t}).then(n=>({...n,items:n.participants}))),events:t=>new R.AsyncCollection(({nextToken:s})=>this.listEvents({nextToken:s,...t}).then(n=>({...n,items:n.events}))),messages:t=>new R.AsyncCollection(({nextToken:s})=>this.listMessages({nextToken:s,...t}).then(n=>({...n,items:n.messages}))),users:t=>new R.AsyncCollection(({nextToken:s})=>this.listUsers({nextToken:s,...t}).then(n=>({...n,items:n.users})))}}};var Wg={};te(Wg,{Client:()=>zs});var OA={getRandomValues:e=>new Uint8Array(e.map(()=>Math.floor(Math.random()*256)))},VA=typeof globalThis.crypto<"u"&&typeof globalThis.crypto.getRandomValues=="function"?globalThis.crypto:OA,w=class e extends Error{constructor(s,n,a,o,i,p,u){super(o);this.code=s;this.description=n;this.type=a;this.message=o;this.error=i;this.id=p;this.metadata=u;this.id||(this.id=e.generateId())}isApiError=!0;format(){return`[${this.type}] ${this.message} (Error ID: ${this.id})`}toJSON(){return{id:this.id,code:this.code,type:this.type,message:this.message,metadata:this.metadata}}static generateId(){let s=this.getPrefix(),n=new Date().toISOString().replace(/[\-:TZ]/g,"").split(".")[0],a=4,o=Array.from(VA.getRandomValues(new Uint8Array(a))).map(i=>i.toString(16).padStart(2,"0")).join("").toUpperCase();return`${s}_${n}x${o}`}static getPrefix(){return typeof window<"u"&&typeof window.document<"u"?"err_bwsr":"err"}},NA=e=>typeof e=="object"&&!Array.isArray(e)&&e!==null,KA=e=>e instanceof w||NA(e)&&e.isApiError===!0,ke=class extends w{constructor(t,s,n,a){super(500,"An unknown error occurred","Unknown",t,s,n,a)}},xs=class extends w{constructor(t,s,n,a){super(500,"An internal error occurred","Internal",t,s,n,a)}},ks=class extends w{constructor(t,s,n,a){super(401,"The request requires to be authenticated.","Unauthorized",t,s,n,a)}},Ps=class extends w{constructor(t,s,n,a){super(403,"The requested action can't be peform by this resource.","Forbidden",t,s,n,a)}},vs=class extends w{constructor(t,s,n,a){super(413,"The request payload is too large.","PayloadTooLarge",t,s,n,a)}},As=class extends w{constructor(t,s,n,a){super(400,"The request payload is invalid.","InvalidPayload",t,s,n,a)}},Cs=class extends w{constructor(t,s,n,a){super(415,"The request is invalid because the content-type is not supported.","UnsupportedMediaType",t,s,n,a)}},Bs=class extends w{constructor(t,s,n,a){super(405,"The requested method does not exist.","MethodNotFound",t,s,n,a)}},Ts=class extends w{constructor(t,s,n,a){super(404,"The requested resource does not exist.","ResourceNotFound",t,s,n,a)}},ws=class extends w{constructor(t,s,n,a){super(400,"The provided JSON schema is invalid.","InvalidJsonSchema",t,s,n,a)}},Us=class extends w{constructor(t,s,n,a){super(400,"The provided data doesn't respect the provided JSON schema.","InvalidDataFormat",t,s,n,a)}},Gs=class extends w{constructor(t,s,n,a){super(400,"The provided identifier is not valid. An identifier must start with a lowercase letter, be between 2 and 100 characters long and use only alphanumeric characters.","InvalidIdentifier",t,s,n,a)}},Ss=class extends w{constructor(t,s,n,a){super(409,"The resource is related with a different resource that the one referenced in the request. This is usually caused when providing two resource identifiers that aren't linked together.","RelationConflict",t,s,n,a)}},Es=class extends w{constructor(t,s,n,a){super(409,"The resource cannot be deleted because it's referenced by another resource","ReferenceConstraint",t,s,n,a)}},Ls=class extends w{constructor(t,s,n,a){super(409,"The resource is current locked and cannot be operated on until the lock is released.","ResourceLockedConflict",t,s,n,a)}},Ws=class extends w{constructor(t,s,n,a){super(410,"The requested resource is no longer available.","ResourceGone",t,s,n,a)}},_s=class extends w{constructor(t,s,n,a){super(400,"The provided resource reference is missing. This is usually caused when providing an invalid id inside the payload of a request.","ReferenceNotFound",t,s,n,a)}},Hs=class extends w{constructor(t,s,n,a){super(400,"The provided query is invalid. This is usually caused when providing an invalid parameter for querying a resource.","InvalidQuery",t,s,n,a)}},Qs=class extends w{constructor(t,s,n,a){super(400,"An error happened during the execution of a runtime (bot or integration).","Runtime",t,s,n,a)}},Ds=class extends w{constructor(t,s,n,a){super(409,"The record attempted to be created already exists.","AlreadyExists",t,s,n,a)}},Fs=class extends w{constructor(t,s,n,a){super(429,"The request has been rate limited.","RateLimited",t,s,n,a)}},Ms=class extends w{constructor(t,s,n,a){super(402,"A payment is required to perform this request.","PaymentRequired",t,s,n,a)}},Os=class extends w{constructor(t,s,n,a){super(403,"The request exceeds the allowed quota. Quotas are a soft limit that can be increased.","QuotaExceeded",t,s,n,a)}},Vs=class extends w{constructor(t,s,n,a){super(413,"The request exceeds the allowed limit. Limits are a hard limit that cannot be increased.","LimitExceeded",t,s,n,a)}},Ns=class extends w{constructor(t,s,n,a){super(400,"Request payload contains breaking changes which is not allowed for this resource without a version increment.","BreakingChanges",t,s,n,a)}},Ks=class extends w{constructor(t,s,n,a){super(504,"The operation timed out.","OperationTimeout",t,s,n,a)}},$A={Unknown:ke,Internal:xs,Unauthorized:ks,Forbidden:Ps,PayloadTooLarge:vs,InvalidPayload:As,UnsupportedMediaType:Cs,MethodNotFound:Bs,ResourceNotFound:Ts,InvalidJsonSchema:ws,InvalidDataFormat:Us,InvalidIdentifier:Gs,RelationConflict:Ss,ReferenceConstraint:Es,ResourceLockedConflict:Ls,ResourceGone:Ws,ReferenceNotFound:_s,InvalidQuery:Hs,Runtime:Qs,AlreadyExists:Ds,RateLimited:Fs,PaymentRequired:Ms,QuotaExceeded:Os,LimitExceeded:Vs,BreakingChanges:Ns,OperationTimeout:Ks},$s=e=>KA(e)?e:e instanceof Error?new ke(e.message,e):typeof e=="string"?new ke(e):zA(e);function zA(e){if(typeof e=="object"&&"code"in e&&"type"in e&&"id"in e&&"message"in e&&typeof e.type=="string"&&typeof e.message=="string"){let t=$A[e.type];return t?new t(e.message,void 0,e.id||"UNKNOWN",e.metadata):new ke(`An unclassified API error occurred: ${e.message} (Type: ${e.type}, Code: ${e.code})`)}return new ke("An invalid error occurred: "+JSON.stringify(e))}var Tu=Te(xe()),JA=e=>e[1]!==void 0,l=e=>{let{method:t,path:s,query:n,headers:a,body:o}=e,i=Object.entries(a).filter(JA),p=Object.fromEntries(i),u=Tu.default.stringify(n,{encode:!0,arrayFormat:"repeat",allowDots:!0}),r=u?[s,u].join("?"):s,y=["put","post","delete","patch"].includes(t.toLowerCase())?o:void 0;return{method:t,url:r,headers:p,data:y}};var wu=e=>({path:"/v1/admin/helper/vrl",headers:{},query:{},params:{},body:{data:e.data,script:e.script}});var Gu=e=>({path:"/v1/admin/account/me",headers:{},query:{},params:{},body:{}});var Eu=e=>({path:"/v1/admin/account/me",headers:{},query:{},params:{},body:{displayName:e.displayName,profilePicture:e.profilePicture,refresh:e.refresh}});var Wu=e=>({path:"/v1/admin/account/me",headers:{},query:{},params:{},body:{}});var Hu=e=>({path:"/v1/admin/account/pats",headers:{},query:{},params:{},body:{}});var Du=e=>({path:"/v1/admin/account/pats",headers:{},query:{},params:{},body:{note:e.note}});var Mu=e=>({path:`/v1/admin/account/pats/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Vu=e=>({path:`/v1/admin/account/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{value:e.value}});var Ku=e=>({path:`/v1/admin/account/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{}});var zu=e=>({path:"/v1/admin/hub/integrations",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,limit:e.limit,name:e.name,version:e.version,interfaceId:e.interfaceId,interfaceName:e.interfaceName,installedByBotId:e.installedByBotId,verificationStatus:e.verificationStatus,search:e.search,sortBy:e.sortBy,direction:e.direction},params:{},body:{}});var ju=e=>({path:`/v1/admin/hub/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Zu=e=>({path:`/v1/admin/hub/integrations/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var ec=e=>({path:"/v1/admin/hub/plugins",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var rc=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var nc=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.id)}/dereferenced`,headers:{},query:{interfaces:e.interfaces},params:{id:e.id},body:{}});var oc=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var pc=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.id)}/code/${encodeURIComponent(e.platform)}`,headers:{},query:{},params:{id:e.id,platform:e.platform},body:{}});var cc=e=>({path:"/v1/admin/hub/interfaces",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var lc=e=>({path:`/v1/admin/hub/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var yc=e=>({path:`/v1/admin/hub/interfaces/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var Rc=e=>({path:"/v1/admin/bots",headers:{},query:{},params:{},body:{states:e.states,events:e.events,recurringEvents:e.recurringEvents,actions:e.actions,configuration:e.configuration,user:e.user,conversation:e.conversation,message:e.message,tags:e.tags,maxExecutionTime:e.maxExecutionTime,subscriptions:e.subscriptions,code:e.code,name:e.name,description:e.description,medias:e.medias,url:e.url,secrets:e.secrets,dev:e.dev,type:e.type,moduleFormat:e.moduleFormat}});var hc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{url:e.url,authentication:e.authentication,configuration:e.configuration,maxExecutionTime:e.maxExecutionTime,blocked:e.blocked,alwaysAlive:e.alwaysAlive,tags:e.tags,user:e.user,message:e.message,conversation:e.conversation,events:e.events,actions:e.actions,states:e.states,recurringEvents:e.recurringEvents,integrations:e.integrations,plugins:e.plugins,subscriptions:e.subscriptions,code:e.code,name:e.name,description:e.description,medias:e.medias,secrets:e.secrets,layers:e.layers,type:e.type,moduleFormat:e.moduleFormat}});var fc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/signing-secrets/rotate`,headers:{},query:{},params:{id:e.id},body:{}});var xc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/transfer`,headers:{},query:{},params:{id:e.id},body:{targetWorkspaceId:e.targetWorkspaceId}});var Pc=e=>({path:"/v1/admin/bots",headers:{},query:{dev:e.dev,tags:e.tags,integrationNames:e.integrationNames,pluginNames:e.pluginNames,nextToken:e.nextToken,pageSize:e.pageSize,sortField:e.sortField,sortDirection:e.sortDirection},params:{},body:{}});var Ac=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Bc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var wc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/logs`,headers:{},query:{timeStart:e.timeStart,timeEnd:e.timeEnd,level:e.level,userId:e.userId,workflowId:e.workflowId,conversationId:e.conversationId,messageContains:e.messageContains,nextToken:e.nextToken},params:{id:e.id},body:{}});var Gc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/webchat`,headers:{},query:{type:e.type},params:{id:e.id},body:{}});var Ec=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/analytics`,headers:{},query:{startDate:e.startDate,endDate:e.endDate},params:{id:e.id},body:{}});var Wc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/action-runs`,headers:{},query:{integrationName:e.integrationName,timestampFrom:e.timestampFrom,timestampUntil:e.timestampUntil,nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var Hc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues/${encodeURIComponent(e.issueId)}`,headers:{},query:{},params:{id:e.id,issueId:e.issueId},body:{}});var Dc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var Mc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues/${encodeURIComponent(e.issueId)}`,headers:{},query:{},params:{id:e.id,issueId:e.issueId},body:{}});var Vc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues/${encodeURIComponent(e.issueId)}/events`,headers:{},query:{},params:{id:e.id,issueId:e.issueId},body:{}});var Kc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions`,headers:{},query:{},params:{id:e.id},body:{}});var zc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions/${encodeURIComponent(e.versionId)}`,headers:{},query:{},params:{id:e.id,versionId:e.versionId},body:{}});var jc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/bot-json`,headers:{},query:{},params:{id:e.id},body:{}});var Zc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/publish-from-bot-json`,headers:{},query:{},params:{id:e.id},body:{botJson:e.botJson}});var ed=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions`,headers:{},query:{},params:{id:e.id},body:{name:e.name,description:e.description}});var rd=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions/deploy`,headers:{},query:{},params:{id:e.id},body:{versionId:e.versionId}});var nd=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/shareable-id`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var od=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/shareable-id`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var pd=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/shareable-id`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var cd=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/sandboxed-conversations`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var ld=e=>({path:"/v1/admin/bots/baks",headers:{},query:{botId:e.botId},params:{},body:{}});var yd=e=>({path:"/v1/admin/bots/baks",headers:{},query:{},params:{},body:{botId:e.botId,note:e.note}});var Rd=e=>({path:`/v1/admin/bots/baks/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var hd=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/allowlist`,headers:{},query:{},params:{botId:e.botId},body:{}});var fd=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/allowlist`,headers:{},query:{},params:{botId:e.botId},body:{setting:e.setting,users:e.users}});var xd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/migrate-to-v4`,headers:{},query:{},params:{id:e.id},body:{}});var Pd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/billing/invoices`,headers:{},query:{},params:{id:e.id},body:{}});var Ad=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/billing/upcoming-invoice`,headers:{},query:{},params:{id:e.id},body:{}});var Bd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/billing/invoices/charge-unpaid`,headers:{},query:{},params:{id:e.id},body:{invoiceIds:e.invoiceIds}});var wd=e=>({path:"/v1/admin/workspaces",headers:{},query:{},params:{},body:{name:e.name,billingVersion:e.billingVersion}});var Gd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/public`,headers:{},query:{},params:{id:e.id},body:{}});var Ed=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Wd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/usages`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var Hd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/usages/by-bot`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var Dd=e=>({path:"/v1/admin/workspaces/usages/quota-completion",headers:{},query:{},params:{},body:{}});var Md=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/quota`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var Vd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/quotas`,headers:{},query:{period:e.period},params:{id:e.id},body:{}});var Kd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{name:e.name,spendingLimit:e.spendingLimit,about:e.about,profilePicture:e.profilePicture,contactEmail:e.contactEmail,website:e.website,socialAccounts:e.socialAccounts,isPublic:e.isPublic,handle:e.handle}});var zd=e=>({path:"/v1/admin/workspaces/handle-availability",headers:{},query:{},params:{},body:{handle:e.handle}});var jd=e=>({path:"/v1/admin/workspaces",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,handle:e.handle},params:{},body:{}});var Zd=e=>({path:"/v1/admin/workspaces/public",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,workspaceIds:e.workspaceIds,search:e.search},params:{},body:{}});var el=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var rl=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/audit-records`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var nl=e=>({path:`/v1/admin/workspaces/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{value:e.value}});var ol=e=>({path:`/v1/admin/workspaces/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{}});var pl=e=>({path:"/v1/admin/workspace-members",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{},body:{}});var cl=e=>({path:"/v1/admin/workspace-members/me",headers:{},query:{},params:{},body:{}});var ll=e=>({path:`/v1/admin/workspace-members/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var yl=e=>({path:"/v1/admin/workspace-members",headers:{},query:{},params:{},body:{email:e.email,role:e.role,sendEmail:e.sendEmail}});var Rl=e=>({path:`/v1/admin/workspace-members/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{role:e.role}});var hl=e=>({path:"/v1/admin/integrations/iaks",headers:{},query:{integrationId:e.integrationId},params:{},body:{}});var fl=e=>({path:"/v1/admin/integrations/iaks",headers:{},query:{},params:{},body:{integrationId:e.integrationId,note:e.note}});var xl=e=>({path:`/v1/admin/integrations/iaks/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Pl=e=>({path:"/v1/admin/integrations",headers:{},query:{},params:{},body:{name:e.name,version:e.version,configuration:e.configuration,configurations:e.configurations,states:e.states,events:e.events,actions:e.actions,entities:e.entities,identifier:e.identifier,channels:e.channels,user:e.user,interfaces:e.interfaces,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,secrets:e.secrets,code:e.code,url:e.url,dev:e.dev,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,layers:e.layers,attributes:e.attributes}});var Al=e=>({path:"/v1/admin/integrations/validate",headers:{},query:{},params:{},body:{name:e.name,version:e.version,configuration:e.configuration,configurations:e.configurations,states:e.states,events:e.events,actions:e.actions,entities:e.entities,identifier:e.identifier,channels:e.channels,user:e.user,interfaces:e.interfaces,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,secrets:e.secrets,code:e.code,url:e.url,dev:e.dev,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,layers:e.layers,attributes:e.attributes}});var Bl=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{configuration:e.configuration,configurations:e.configurations,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,channels:e.channels,maxExecutionTime:e.maxExecutionTime,identifier:e.identifier,actions:e.actions,events:e.events,states:e.states,user:e.user,entities:e.entities,interfaces:e.interfaces,attributes:e.attributes,secrets:e.secrets,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,url:e.url,public:e.public,visibility:e.visibility,layers:e.layers}});var wl=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}/signing-secrets/rotate`,headers:{},query:{},params:{id:e.id},body:{}});var Gl=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}/validate`,headers:{},query:{},params:{id:e.id},body:{configuration:e.configuration,configurations:e.configurations,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,channels:e.channels,maxExecutionTime:e.maxExecutionTime,identifier:e.identifier,actions:e.actions,events:e.events,states:e.states,user:e.user,entities:e.entities,interfaces:e.interfaces,attributes:e.attributes,secrets:e.secrets,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,url:e.url,public:e.public,visibility:e.visibility,layers:e.layers}});var El=e=>({path:"/v1/admin/integrations",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,limit:e.limit,name:e.name,version:e.version,interfaceId:e.interfaceId,interfaceName:e.interfaceName,installedByBotId:e.installedByBotId,verificationStatus:e.verificationStatus,search:e.search,sortBy:e.sortBy,direction:e.direction,visibility:e.visibility,dev:e.dev},params:{},body:{}});var Wl=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Hl=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}/logs`,headers:{},query:{timeStart:e.timeStart,timeEnd:e.timeEnd,level:e.level,userId:e.userId,conversationId:e.conversationId,messageContains:e.messageContains,nextToken:e.nextToken},params:{id:e.id},body:{}});var Dl=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var Ml=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Vl=e=>({path:"/v1/admin/integrations/request-verification",headers:{},query:{},params:{},body:{integrationId:e.integrationId}});var Kl=e=>({path:"/v1/admin/interfaces",headers:{},query:{},params:{},body:{name:e.name,version:e.version,entities:e.entities,events:e.events,actions:e.actions,channels:e.channels,nameTemplate:e.nameTemplate,sdkVersion:e.sdkVersion,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,attributes:e.attributes}});var zl=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var jl=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var Zl=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{entities:e.entities,events:e.events,actions:e.actions,channels:e.channels,nameTemplate:e.nameTemplate,sdkVersion:e.sdkVersion,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,attributes:e.attributes}});var eg=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var rg=e=>({path:"/v1/admin/interfaces",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var ng=e=>({path:"/v1/admin/plugins",headers:{},query:{},params:{},body:{name:e.name,version:e.version,configuration:e.configuration,states:e.states,events:e.events,actions:e.actions,user:e.user,conversation:e.conversation,message:e.message,sdkVersion:e.sdkVersion,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,dependencies:e.dependencies,attributes:e.attributes}});var og=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var pg=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}/dereferenced`,headers:{},query:{interfaces:e.interfaces},params:{id:e.id},body:{}});var cg=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var lg=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{configuration:e.configuration,states:e.states,events:e.events,actions:e.actions,user:e.user,conversation:e.conversation,message:e.message,sdkVersion:e.sdkVersion,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,dependencies:e.dependencies,attributes:e.attributes}});var yg=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Rg=e=>({path:"/v1/admin/plugins",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var hg=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}/code/${encodeURIComponent(e.platform)}`,headers:{},query:{},params:{id:e.id,platform:e.platform},body:{}});var fg=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var xg=e=>({path:"/v1/admin/usages/multiple",headers:{},query:{types:e.types,ids:e.ids,period:e.period},params:{},body:{}});var Pg=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}/history`,headers:{},query:{type:e.type},params:{id:e.id},body:{}});var Ag=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}/activity`,headers:{},query:{type:e.type,timestampFrom:e.timestampFrom,timestampUntil:e.timestampUntil,nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var Bg=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}/daily-activity`,headers:{},query:{type:e.type,dateFrom:e.dateFrom,dateUntil:e.dateUntil,nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var wg=e=>({path:"/v1/admin/quotas/ai-spend",headers:{},query:{},params:{},body:{monthlySpendingLimit:e.monthlySpendingLimit}});var Gg=e=>({path:"/v1/admin/activities",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,taskId:e.taskId,botId:e.botId},params:{},body:{}});var Eg=e=>({path:"/v1/admin/introspect",headers:{},query:{},params:{},body:{botId:e.botId}});var Ct=class{constructor(t,s={}){this.httpClient=t;this.props=s}runVrl=async t=>{let{path:s,headers:n,query:a,body:o}=wu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAccount=async t=>{let{path:s,headers:n,query:a,body:o}=Gu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateAccount=async t=>{let{path:s,headers:n,query:a,body:o}=Eu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteAccount=async t=>{let{path:s,headers:n,query:a,body:o}=Wu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPersonalAccessTokens=async t=>{let{path:s,headers:n,query:a,body:o}=Hu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createPersonalAccessToken=async t=>{let{path:s,headers:n,query:a,body:o}=Du(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deletePersonalAccessToken=async t=>{let{path:s,headers:n,query:a,body:o}=Mu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setAccountPreference=async t=>{let{path:s,headers:n,query:a,body:o}=Vu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAccountPreference=async t=>{let{path:s,headers:n,query:a,body:o}=Ku(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicIntegrations=async t=>{let{path:s,headers:n,query:a,body:o}=zu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicIntegrationById=async t=>{let{path:s,headers:n,query:a,body:o}=ju(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=Zu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicPlugins=async t=>{let{path:s,headers:n,query:a,body:o}=ec(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicPluginById=async t=>{let{path:s,headers:n,query:a,body:o}=rc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getDereferencedPublicPluginById=async t=>{let{path:s,headers:n,query:a,body:o}=nc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=oc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicPluginCode=async t=>{let{path:s,headers:n,query:a,body:o}=pc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicInterfaces=async t=>{let{path:s,headers:n,query:a,body:o}=cc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicInterfaceById=async t=>{let{path:s,headers:n,query:a,body:o}=lc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicInterface=async t=>{let{path:s,headers:n,query:a,body:o}=yc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createBot=async t=>{let{path:s,headers:n,query:a,body:o}=Rc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateBot=async t=>{let{path:s,headers:n,query:a,body:o}=hc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};rotateBotSigningSecrets=async t=>{let{path:s,headers:n,query:a,body:o}=fc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};transferBot=async t=>{let{path:s,headers:n,query:a,body:o}=xc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBots=async t=>{let{path:s,headers:n,query:a,body:o}=Pc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBot=async t=>{let{path:s,headers:n,query:a,body:o}=Ac(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteBot=async t=>{let{path:s,headers:n,query:a,body:o}=Bc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotLogs=async t=>{let{path:s,headers:n,query:a,body:o}=wc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotWebchat=async t=>{let{path:s,headers:n,query:a,body:o}=Gc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotAnalytics=async t=>{let{path:s,headers:n,query:a,body:o}=Ec(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listActionRuns=async t=>{let{path:s,headers:n,query:a,body:o}=Wc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotIssue=async t=>{let{path:s,headers:n,query:a,body:o}=Hc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotIssues=async t=>{let{path:s,headers:n,query:a,body:o}=Dc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteBotIssue=async t=>{let{path:s,headers:n,query:a,body:o}=Mc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotIssueEvents=async t=>{let{path:s,headers:n,query:a,body:o}=Vc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotVersions=async t=>{let{path:s,headers:n,query:a,body:o}=Kc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotVersion=async t=>{let{path:s,headers:n,query:a,body:o}=zc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotJson=async t=>{let{path:s,headers:n,query:a,body:o}=jc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};publishFromBotJson=async t=>{let{path:s,headers:n,query:a,body:o}=Zc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createBotVersion=async t=>{let{path:s,headers:n,query:a,body:o}=ed(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deployBotVersion=async t=>{let{path:s,headers:n,query:a,body:o}=rd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createIntegrationShareableId=async t=>{let{path:s,headers:n,query:a,body:o}=nd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteIntegrationShareableId=async t=>{let{path:s,headers:n,query:a,body:o}=od(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationShareableId=async t=>{let{path:s,headers:n,query:a,body:o}=pd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};unlinkSandboxedConversations=async t=>{let{path:s,headers:n,query:a,body:o}=cd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotApiKeys=async t=>{let{path:s,headers:n,query:a,body:o}=ld(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createBotApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=yd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteBotApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=Rd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotAllowlist=async t=>{let{path:s,headers:n,query:a,body:o}=hd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateBotAllowlist=async t=>{let{path:s,headers:n,query:a,body:o}=fd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};migrateWorkspaceToV4=async t=>{let{path:s,headers:n,query:a,body:o}=xd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceInvoices=async t=>{let{path:s,headers:n,query:a,body:o}=Pd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getUpcomingInvoice=async t=>{let{path:s,headers:n,query:a,body:o}=Ad(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};chargeWorkspaceUnpaidInvoices=async t=>{let{path:s,headers:n,query:a,body:o}=Bd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=wd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=Gd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=Ed(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceUsages=async t=>{let{path:s,headers:n,query:a,body:o}=Wd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};breakDownWorkspaceUsageByBot=async t=>{let{path:s,headers:n,query:a,body:o}=Hd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAllWorkspaceQuotaCompletion=async t=>{let{path:s,headers:n,query:a,body:o}=Dd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspaceQuota=async t=>{let{path:s,headers:n,query:a,body:o}=Md(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceQuotas=async t=>{let{path:s,headers:n,query:a,body:o}=Vd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=Kd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};checkHandleAvailability=async t=>{let{path:s,headers:n,query:a,body:o}=zd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaces=async t=>{let{path:s,headers:n,query:a,body:o}=jd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicWorkspaces=async t=>{let{path:s,headers:n,query:a,body:o}=Zd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=el(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAuditRecords=async t=>{let{path:s,headers:n,query:a,body:o}=rl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setWorkspacePreference=async t=>{let{path:s,headers:n,query:a,body:o}=nl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspacePreference=async t=>{let{path:s,headers:n,query:a,body:o}=ol(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceMembers=async t=>{let{path:s,headers:n,query:a,body:o}=pl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=cl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=ll(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=yl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=Rl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listIntegrationApiKeys=async t=>{let{path:s,headers:n,query:a,body:o}=hl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createIntegrationApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=fl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteIntegrationApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=xl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=Pl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};validateIntegrationCreation=async t=>{let{path:s,headers:n,query:a,body:o}=Al(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=Bl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};rotateIntegrationSigningSecrets=async t=>{let{path:s,headers:n,query:a,body:o}=wl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};validateIntegrationUpdate=async t=>{let{path:s,headers:n,query:a,body:o}=Gl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listIntegrations=async t=>{let{path:s,headers:n,query:a,body:o}=El(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=Wl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationLogs=async t=>{let{path:s,headers:n,query:a,body:o}=Hl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationByName=async t=>{let{path:s,headers:n,query:a,body:o}=Dl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=Ml(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};requestIntegrationVerification=async t=>{let{path:s,headers:n,query:a,body:o}=Vl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createInterface=async t=>{let{path:s,headers:n,query:a,body:o}=Kl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getInterface=async t=>{let{path:s,headers:n,query:a,body:o}=zl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getInterfaceByName=async t=>{let{path:s,headers:n,query:a,body:o}=jl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateInterface=async t=>{let{path:s,headers:n,query:a,body:o}=Zl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteInterface=async t=>{let{path:s,headers:n,query:a,body:o}=eg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listInterfaces=async t=>{let{path:s,headers:n,query:a,body:o}=rg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=ng(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=og(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getDereferencedPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=pg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPluginByName=async t=>{let{path:s,headers:n,query:a,body:o}=cg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updatePlugin=async t=>{let{path:s,headers:n,query:a,body:o}=lg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deletePlugin=async t=>{let{path:s,headers:n,query:a,body:o}=yg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPlugins=async t=>{let{path:s,headers:n,query:a,body:o}=Rg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPluginCode=async t=>{let{path:s,headers:n,query:a,body:o}=hg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getUsage=async t=>{let{path:s,headers:n,query:a,body:o}=fg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getMultipleUsages=async t=>{let{path:s,headers:n,query:a,body:o}=xg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsageHistory=async t=>{let{path:s,headers:n,query:a,body:o}=Pg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsageActivity=async t=>{let{path:s,headers:n,query:a,body:o}=Ag(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsageActivityDaily=async t=>{let{path:s,headers:n,query:a,body:o}=Bg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};changeAISpendQuota=async t=>{let{path:s,headers:n,query:a,body:o}=wg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listActivities=async t=>{let{path:s,headers:n,query:a,body:o}=Gg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};introspect=async t=>{let{path:s,headers:n,query:a,body:o}=Eg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})}};function g(e){let t=e?.response?.data;return t?$s(t):$s(e)}var zs=class extends Ct{config;constructor(t){let s=$.getClientConfig(t),n=W.createHttpClient(s);super(n,{toApiError:z.toApiError}),t.retry&&(n.retry=t.retry),this.config=s}get list(){return{publicIntegrations:t=>new R.AsyncCollection(({nextToken:s})=>this.listPublicIntegrations({nextToken:s,...t}).then(n=>({...n,items:n.integrations}))),bots:t=>new R.AsyncCollection(({nextToken:s})=>this.listBots({nextToken:s,...t}).then(n=>({...n,items:n.bots}))),botIssues:t=>new R.AsyncCollection(({nextToken:s})=>this.listBotIssues({nextToken:s,...t}).then(n=>({...n,items:n.issues}))),workspaces:t=>new R.AsyncCollection(({nextToken:s})=>this.listWorkspaces({nextToken:s,...t}).then(n=>({...n,items:n.workspaces}))),publicWorkspaces:t=>new R.AsyncCollection(({nextToken:s})=>this.listPublicWorkspaces({nextToken:s,...t}).then(n=>({...n,items:n.workspaces}))),workspaceMembers:t=>new R.AsyncCollection(({nextToken:s})=>this.listWorkspaceMembers({nextToken:s,...t}).then(n=>({...n,items:n.members}))),integrations:t=>new R.AsyncCollection(({nextToken:s})=>this.listIntegrations({nextToken:s,...t}).then(n=>({...n,items:n.integrations}))),interfaces:t=>new R.AsyncCollection(({nextToken:s})=>this.listInterfaces({nextToken:s,...t}).then(n=>({...n,items:n.interfaces}))),activities:t=>new R.AsyncCollection(({nextToken:s})=>this.listActivities({nextToken:s,...t}).then(n=>({...n,items:n.activities}))),usageActivity:t=>new R.AsyncCollection(({nextToken:s})=>this.listUsageActivity({nextToken:s,...t}).then(n=>({...n,items:n.data}))),usageActivityDaily:t=>new R.AsyncCollection(({nextToken:s})=>this.listUsageActivityDaily({nextToken:s,...t}).then(n=>({...n,items:n.data})))}}};var My={};te(My,{Client:()=>xn});var YA={getRandomValues:e=>new Uint8Array(e.map(()=>Math.floor(Math.random()*256)))},ZA=typeof globalThis.crypto<"u"&&typeof globalThis.crypto.getRandomValues=="function"?globalThis.crypto:YA,U=class e extends Error{constructor(s,n,a,o,i,p,u){super(o);this.code=s;this.description=n;this.type=a;this.message=o;this.error=i;this.id=p;this.metadata=u;this.id||(this.id=e.generateId())}isApiError=!0;format(){return`[${this.type}] ${this.message} (Error ID: ${this.id})`}toJSON(){return{id:this.id,code:this.code,type:this.type,message:this.message,metadata:this.metadata}}static generateId(){let s=this.getPrefix(),n=new Date().toISOString().replace(/[\-:TZ]/g,"").split(".")[0],a=4,o=Array.from(ZA.getRandomValues(new Uint8Array(a))).map(i=>i.toString(16).padStart(2,"0")).join("").toUpperCase();return`${s}_${n}x${o}`}static getPrefix(){return typeof window<"u"&&typeof window.document<"u"?"err_bwsr":"err"}},XA=e=>typeof e=="object"&&!Array.isArray(e)&&e!==null,eC=e=>e instanceof U||XA(e)&&e.isApiError===!0,Pe=class extends U{constructor(t,s,n,a){super(500,"An unknown error occurred","Unknown",t,s,n,a)}},Js=class extends U{constructor(t,s,n,a){super(500,"An internal error occurred","Internal",t,s,n,a)}},js=class extends U{constructor(t,s,n,a){super(401,"The request requires to be authenticated.","Unauthorized",t,s,n,a)}},Ys=class extends U{constructor(t,s,n,a){super(403,"The requested action can't be peform by this resource.","Forbidden",t,s,n,a)}},Zs=class extends U{constructor(t,s,n,a){super(413,"The request payload is too large.","PayloadTooLarge",t,s,n,a)}},Xs=class extends U{constructor(t,s,n,a){super(400,"The request payload is invalid.","InvalidPayload",t,s,n,a)}},en=class extends U{constructor(t,s,n,a){super(415,"The request is invalid because the content-type is not supported.","UnsupportedMediaType",t,s,n,a)}},tn=class extends U{constructor(t,s,n,a){super(405,"The requested method does not exist.","MethodNotFound",t,s,n,a)}},rn=class extends U{constructor(t,s,n,a){super(404,"The requested resource does not exist.","ResourceNotFound",t,s,n,a)}},sn=class extends U{constructor(t,s,n,a){super(400,"The provided JSON schema is invalid.","InvalidJsonSchema",t,s,n,a)}},nn=class extends U{constructor(t,s,n,a){super(400,"The provided data doesn't respect the provided JSON schema.","InvalidDataFormat",t,s,n,a)}},an=class extends U{constructor(t,s,n,a){super(400,"The provided identifier is not valid. An identifier must start with a lowercase letter, be between 2 and 100 characters long and use only alphanumeric characters.","InvalidIdentifier",t,s,n,a)}},on=class extends U{constructor(t,s,n,a){super(409,"The resource is related with a different resource that the one referenced in the request. This is usually caused when providing two resource identifiers that aren't linked together.","RelationConflict",t,s,n,a)}},pn=class extends U{constructor(t,s,n,a){super(409,"The resource cannot be deleted because it's referenced by another resource","ReferenceConstraint",t,s,n,a)}},un=class extends U{constructor(t,s,n,a){super(409,"The resource is current locked and cannot be operated on until the lock is released.","ResourceLockedConflict",t,s,n,a)}},cn=class extends U{constructor(t,s,n,a){super(410,"The requested resource is no longer available.","ResourceGone",t,s,n,a)}},dn=class extends U{constructor(t,s,n,a){super(400,"The provided resource reference is missing. This is usually caused when providing an invalid id inside the payload of a request.","ReferenceNotFound",t,s,n,a)}},ln=class extends U{constructor(t,s,n,a){super(400,"The provided query is invalid. This is usually caused when providing an invalid parameter for querying a resource.","InvalidQuery",t,s,n,a)}},gn=class extends U{constructor(t,s,n,a){super(400,"An error happened during the execution of a runtime (bot or integration).","Runtime",t,s,n,a)}},yn=class extends U{constructor(t,s,n,a){super(409,"The record attempted to be created already exists.","AlreadyExists",t,s,n,a)}},mn=class extends U{constructor(t,s,n,a){super(429,"The request has been rate limited.","RateLimited",t,s,n,a)}},Rn=class extends U{constructor(t,s,n,a){super(402,"A payment is required to perform this request.","PaymentRequired",t,s,n,a)}},qn=class extends U{constructor(t,s,n,a){super(403,"The request exceeds the allowed quota. Quotas are a soft limit that can be increased.","QuotaExceeded",t,s,n,a)}},hn=class extends U{constructor(t,s,n,a){super(413,"The request exceeds the allowed limit. Limits are a hard limit that cannot be increased.","LimitExceeded",t,s,n,a)}},bn=class extends U{constructor(t,s,n,a){super(400,"Request payload contains breaking changes which is not allowed for this resource without a version increment.","BreakingChanges",t,s,n,a)}},fn=class extends U{constructor(t,s,n,a){super(504,"The operation timed out.","OperationTimeout",t,s,n,a)}},tC={Unknown:Pe,Internal:Js,Unauthorized:js,Forbidden:Ys,PayloadTooLarge:Zs,InvalidPayload:Xs,UnsupportedMediaType:en,MethodNotFound:tn,ResourceNotFound:rn,InvalidJsonSchema:sn,InvalidDataFormat:nn,InvalidIdentifier:an,RelationConflict:on,ReferenceConstraint:pn,ResourceLockedConflict:un,ResourceGone:cn,ReferenceNotFound:dn,InvalidQuery:ln,Runtime:gn,AlreadyExists:yn,RateLimited:mn,PaymentRequired:Rn,QuotaExceeded:qn,LimitExceeded:hn,BreakingChanges:bn,OperationTimeout:fn},In=e=>eC(e)?e:e instanceof Error?new Pe(e.message,e):typeof e=="string"?new Pe(e):rC(e);function rC(e){if(typeof e=="object"&&"code"in e&&"type"in e&&"id"in e&&"message"in e&&typeof e.type=="string"&&typeof e.message=="string"){let t=tC[e.type];return t?new t(e.message,void 0,e.id||"UNKNOWN",e.metadata):new Pe(`An unclassified API error occurred: ${e.message} (Type: ${e.type}, Code: ${e.code})`)}return new Pe("An invalid error occurred: "+JSON.stringify(e))}var _g=Te(xe()),sC=e=>e[1]!==void 0,C=e=>{let{method:t,path:s,query:n,headers:a,body:o}=e,i=Object.entries(a).filter(sC),p=Object.fromEntries(i),u=_g.default.stringify(n,{encode:!0,arrayFormat:"repeat",allowDots:!0}),r=u?[s,u].join("?"):s,y=["put","post","delete","patch"].includes(t.toLowerCase())?o:void 0;return{method:t,url:r,headers:p,data:y}};var Hg=e=>({path:"/v2/billing/readonly",headers:{},query:{},params:{},body:{}});var Dg=e=>({path:"/v2/billing/address",headers:{},query:{},params:{},body:{}});var Mg=e=>({path:"/v2/billing/address",headers:{},query:{},params:{},body:{lineOne:e.lineOne,lineTwo:e.lineTwo,city:e.city,state:e.state,postalCode:e.postalCode,country:e.country}});var Vg=e=>({path:"/v2/billing/customer",headers:{},query:{},params:{},body:{}});var Kg=e=>({path:"/v2/billing/customer",headers:{},query:{},params:{},body:{address:e.address,name:e.name,taxIds:e.taxIds}});var zg=e=>({path:`/v2/billing/plans/${encodeURIComponent(e.planId)}`,headers:{},query:{},params:{planId:e.planId},body:{}});var jg=e=>({path:"/v2/billing/plans",headers:{},query:{},params:{},body:{}});var Zg=e=>({path:`/v2/billing/addons/${encodeURIComponent(e.addonId)}`,headers:{},query:{},params:{addonId:e.addonId},body:{}});var ey=e=>({path:"/v2/billing/addons",headers:{},query:{},params:{},body:{}});var ry=e=>({path:"/v2/billing/subscriptions",headers:{},query:{},params:{},body:{}});var ny=e=>({path:"/v2/billing/subscriptions/preview",headers:{},query:{},params:{},body:{plan:e.plan,addons:e.addons,couponCode:e.couponCode}});var oy=e=>({path:"/v2/billing/plans",headers:{},query:{},params:{},body:{planId:e.planId,interval:e.interval,testReferenceTime:e.testReferenceTime,couponCode:e.couponCode}});var py=e=>({path:"/v2/billing/addons",headers:{},query:{},params:{},body:{addons:e.addons,couponCode:e.couponCode}});var cy=e=>({path:"/v2/billing/subscriptions/cancel",headers:{},query:{},params:{},body:{}});var ly=e=>({path:"/v2/billing/auto-recharge/settings",headers:{},query:{},params:{},body:{}});var yy=e=>({path:"/v2/billing/auto-recharge/settings",headers:{},query:{},params:{},body:{settings:e.settings}});var Ry=e=>({path:"/v2/billing/trials",headers:{},query:{},params:{},body:{}});var hy=e=>({path:"/v2/billing/trials",headers:{},query:{},params:{},body:{lengthInDays:e.lengthInDays,plan:e.plan}});var fy=e=>({path:"/v2/billing/trials",headers:{},query:{},params:{},body:{}});var xy=e=>({path:"/v2/billing/credit-grants",headers:{},query:{},params:{},body:{amount:e.amount,feature:e.feature}});var Py=e=>({path:"/v2/billing/invoices",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{},body:{}});var Ay=e=>({path:`/v2/billing/invoices/${encodeURIComponent(e.invoiceId)}/pay`,headers:{},query:{},params:{invoiceId:e.invoiceId},body:{idempotencyKey:e.idempotencyKey}});var By=e=>({path:"/v2/billing/payment-methods",headers:{},query:{},params:{},body:{}});var wy=e=>({path:"/v2/billing/payment-methods",headers:{},query:{},params:{},body:{paymentMethodId:e.paymentMethodId}});var Gy=e=>({path:"/v2/billing/payment-methods/intent",headers:{},query:{},params:{},body:{}});var Ey=e=>({path:"/v2/billing/quotas",headers:{},query:{},params:{},body:{}});var Wy=e=>({path:"/v2/usage/workspace-usage",headers:{},query:{feature:e.feature,period:e.period},params:{},body:{}});var Hy=e=>({path:"/v2/usage/workspace-usages",headers:{},query:{period:e.period},params:{},body:{}});var Dy=e=>({path:"/v2/feature-gate/list",headers:{},query:{},params:{},body:{}});var Bt=class{constructor(t,s={}){this.httpClient=t;this.props=s}getBillingReadonly=async t=>{let{path:s,headers:n,query:a,body:o}=Hg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBillingAddress=async t=>{let{path:s,headers:n,query:a,body:o}=Dg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setBillingAddress=async t=>{let{path:s,headers:n,query:a,body:o}=Mg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getCustomer=async t=>{let{path:s,headers:n,query:a,body:o}=Vg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setCustomer=async t=>{let{path:s,headers:n,query:a,body:o}=Kg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"patch",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPlan=async t=>{let{path:s,headers:n,query:a,body:o}=zg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPlans=async t=>{let{path:s,headers:n,query:a,body:o}=jg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAddon=async t=>{let{path:s,headers:n,query:a,body:o}=Zg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listAddons=async t=>{let{path:s,headers:n,query:a,body:o}=ey(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getSubscription=async t=>{let{path:s,headers:n,query:a,body:o}=ry(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};previewSubscriptionUpdate=async t=>{let{path:s,headers:n,query:a,body:o}=ny(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setPlan=async t=>{let{path:s,headers:n,query:a,body:o}=oy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setAddons=async t=>{let{path:s,headers:n,query:a,body:o}=py(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"patch",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setCancelAtPeriodEnd=async t=>{let{path:s,headers:n,query:a,body:o}=cy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAutoRechargeSettings=async t=>{let{path:s,headers:n,query:a,body:o}=ly(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setAutoRechargeSettings=async t=>{let{path:s,headers:n,query:a,body:o}=yy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getTrials=async t=>{let{path:s,headers:n,query:a,body:o}=Ry(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createTrial=async t=>{let{path:s,headers:n,query:a,body:o}=hy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};removeTrial=async t=>{let{path:s,headers:n,query:a,body:o}=fy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createCreditGrant=async t=>{let{path:s,headers:n,query:a,body:o}=xy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listInvoices=async t=>{let{path:s,headers:n,query:a,body:o}=Py(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};payInvoice=async t=>{let{path:s,headers:n,query:a,body:o}=Ay(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPaymentMethod=async t=>{let{path:s,headers:n,query:a,body:o}=By(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setPaymentMethod=async t=>{let{path:s,headers:n,query:a,body:o}=wy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createPaymentMethodIntent=async t=>{let{path:s,headers:n,query:a,body:o}=Gy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getQuotas=async t=>{let{path:s,headers:n,query:a,body:o}=Ey(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspaceUsage=async t=>{let{path:s,headers:n,query:a,body:o}=Wy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspaceUsages=async t=>{let{path:s,headers:n,query:a,body:o}=Hy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFeatureGates=async t=>{let{path:s,headers:n,query:a,body:o}=Dy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})}};function G(e){let t=e?.response?.data;return t?In(t):In(e)}var xn=class extends Bt{config;constructor(t){let s=$.getClientConfig(t),n=W.createHttpClient(s);super(n,{toApiError:z.toApiError}),t.retry&&(n.retry=t.retry),this.config=s}get list(){return{listInvoices:t=>new R.AsyncCollection(({nextToken:s})=>this.listInvoices({nextToken:s,...t}).then(n=>({...n,items:n.invoices})))}}};var Im={};te(Im,{Client:()=>Jn});var aC={getRandomValues:e=>new Uint8Array(e.map(()=>Math.floor(Math.random()*256)))},oC=typeof globalThis.crypto<"u"&&typeof globalThis.crypto.getRandomValues=="function"?globalThis.crypto:aC,S=class e extends Error{constructor(s,n,a,o,i,p,u){super(o);this.code=s;this.description=n;this.type=a;this.message=o;this.error=i;this.id=p;this.metadata=u;this.id||(this.id=e.generateId())}isApiError=!0;format(){return`[${this.type}] ${this.message} (Error ID: ${this.id})`}toJSON(){return{id:this.id,code:this.code,type:this.type,message:this.message,metadata:this.metadata}}static generateId(){let s=this.getPrefix(),n=new Date().toISOString().replace(/[\-:TZ]/g,"").split(".")[0],a=4,o=Array.from(oC.getRandomValues(new Uint8Array(a))).map(i=>i.toString(16).padStart(2,"0")).join("").toUpperCase();return`${s}_${n}x${o}`}static getPrefix(){return typeof window<"u"&&typeof window.document<"u"?"err_bwsr":"err"}},iC=e=>typeof e=="object"&&!Array.isArray(e)&&e!==null,pC=e=>e instanceof S||iC(e)&&e.isApiError===!0,ve=class extends S{constructor(t,s,n,a){super(500,"An unknown error occurred","Unknown",t,s,n,a)}},kn=class extends S{constructor(t,s,n,a){super(500,"An internal error occurred","Internal",t,s,n,a)}},Pn=class extends S{constructor(t,s,n,a){super(401,"The request requires to be authenticated.","Unauthorized",t,s,n,a)}},vn=class extends S{constructor(t,s,n,a){super(403,"The requested action can't be peform by this resource.","Forbidden",t,s,n,a)}},An=class extends S{constructor(t,s,n,a){super(413,"The request payload is too large.","PayloadTooLarge",t,s,n,a)}},Cn=class extends S{constructor(t,s,n,a){super(400,"The request payload is invalid.","InvalidPayload",t,s,n,a)}},Bn=class extends S{constructor(t,s,n,a){super(415,"The request is invalid because the content-type is not supported.","UnsupportedMediaType",t,s,n,a)}},Tn=class extends S{constructor(t,s,n,a){super(405,"The requested method does not exist.","MethodNotFound",t,s,n,a)}},wn=class extends S{constructor(t,s,n,a){super(404,"The requested resource does not exist.","ResourceNotFound",t,s,n,a)}},Un=class extends S{constructor(t,s,n,a){super(400,"The provided JSON schema is invalid.","InvalidJsonSchema",t,s,n,a)}},Gn=class extends S{constructor(t,s,n,a){super(400,"The provided data doesn't respect the provided JSON schema.","InvalidDataFormat",t,s,n,a)}},Sn=class extends S{constructor(t,s,n,a){super(400,"The provided identifier is not valid. An identifier must start with a lowercase letter, be between 2 and 100 characters long and use only alphanumeric characters.","InvalidIdentifier",t,s,n,a)}},En=class extends S{constructor(t,s,n,a){super(409,"The resource is related with a different resource that the one referenced in the request. This is usually caused when providing two resource identifiers that aren't linked together.","RelationConflict",t,s,n,a)}},Ln=class extends S{constructor(t,s,n,a){super(409,"The resource cannot be deleted because it's referenced by another resource","ReferenceConstraint",t,s,n,a)}},Wn=class extends S{constructor(t,s,n,a){super(409,"The resource is current locked and cannot be operated on until the lock is released.","ResourceLockedConflict",t,s,n,a)}},_n=class extends S{constructor(t,s,n,a){super(410,"The requested resource is no longer available.","ResourceGone",t,s,n,a)}},Hn=class extends S{constructor(t,s,n,a){super(400,"The provided resource reference is missing. This is usually caused when providing an invalid id inside the payload of a request.","ReferenceNotFound",t,s,n,a)}},Qn=class extends S{constructor(t,s,n,a){super(400,"The provided query is invalid. This is usually caused when providing an invalid parameter for querying a resource.","InvalidQuery",t,s,n,a)}},Dn=class extends S{constructor(t,s,n,a){super(400,"An error happened during the execution of a runtime (bot or integration).","Runtime",t,s,n,a)}},Fn=class extends S{constructor(t,s,n,a){super(409,"The record attempted to be created already exists.","AlreadyExists",t,s,n,a)}},Mn=class extends S{constructor(t,s,n,a){super(429,"The request has been rate limited.","RateLimited",t,s,n,a)}},On=class extends S{constructor(t,s,n,a){super(402,"A payment is required to perform this request.","PaymentRequired",t,s,n,a)}},Vn=class extends S{constructor(t,s,n,a){super(403,"The request exceeds the allowed quota. Quotas are a soft limit that can be increased.","QuotaExceeded",t,s,n,a)}},Nn=class extends S{constructor(t,s,n,a){super(413,"The request exceeds the allowed limit. Limits are a hard limit that cannot be increased.","LimitExceeded",t,s,n,a)}},Kn=class extends S{constructor(t,s,n,a){super(400,"Request payload contains breaking changes which is not allowed for this resource without a version increment.","BreakingChanges",t,s,n,a)}},$n=class extends S{constructor(t,s,n,a){super(504,"The operation timed out.","OperationTimeout",t,s,n,a)}},uC={Unknown:ve,Internal:kn,Unauthorized:Pn,Forbidden:vn,PayloadTooLarge:An,InvalidPayload:Cn,UnsupportedMediaType:Bn,MethodNotFound:Tn,ResourceNotFound:wn,InvalidJsonSchema:Un,InvalidDataFormat:Gn,InvalidIdentifier:Sn,RelationConflict:En,ReferenceConstraint:Ln,ResourceLockedConflict:Wn,ResourceGone:_n,ReferenceNotFound:Hn,InvalidQuery:Qn,Runtime:Dn,AlreadyExists:Fn,RateLimited:Mn,PaymentRequired:On,QuotaExceeded:Vn,LimitExceeded:Nn,BreakingChanges:Kn,OperationTimeout:$n},zn=e=>pC(e)?e:e instanceof Error?new ve(e.message,e):typeof e=="string"?new ve(e):cC(e);function cC(e){if(typeof e=="object"&&"code"in e&&"type"in e&&"id"in e&&"message"in e&&typeof e.type=="string"&&typeof e.message=="string"){let t=uC[e.type];return t?new t(e.message,void 0,e.id||"UNKNOWN",e.metadata):new ve(`An unclassified API error occurred: ${e.message} (Type: ${e.type}, Code: ${e.code})`)}return new ve("An invalid error occurred: "+JSON.stringify(e))}var Oy=Te(xe()),dC=e=>e[1]!==void 0,V=e=>{let{method:t,path:s,query:n,headers:a,body:o}=e,i=Object.entries(a).filter(dC),p=Object.fromEntries(i),u=Oy.default.stringify(n,{encode:!0,arrayFormat:"repeat",allowDots:!0}),r=u?[s,u].join("?"):s,y=["put","post","delete","patch"].includes(t.toLowerCase())?o:void 0;return{method:t,url:r,headers:p,data:y}};var Vy=e=>({path:"/v1/files",headers:{},query:{},params:{},body:{key:e.key,tags:e.tags,size:e.size,index:e.index,indexing:e.indexing,accessPolicies:e.accessPolicies,contentType:e.contentType,expiresAt:e.expiresAt,publicContentImmediatelyAccessible:e.publicContentImmediatelyAccessible,metadata:e.metadata}});var Ky=e=>({path:`/v1/files/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var zy=e=>({path:"/v1/files",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,sortField:e.sortField,sortDirection:e.sortDirection,tags:e.tags,ids:e.ids,indexed:e.indexed},params:{},body:{}});var jy=e=>({path:`/v1/files/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Zy=e=>({path:`/v1/files/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{metadata:e.metadata,tags:e.tags,accessPolicies:e.accessPolicies,expiresAt:e.expiresAt}});var em=e=>({path:`/v1/files/${encodeURIComponent(e.idOrKey)}/${encodeURIComponent(e.destinationKey)}`,headers:{"x-destination-bot-id":e["x-destination-bot-id"]},query:{},params:{idOrKey:e.idOrKey,destinationKey:e.destinationKey},body:{overwrite:e.overwrite}});var rm=e=>({path:"/v1/files/search",headers:{},query:{tags:e.tags,query:e.query,contextDepth:e.contextDepth,limit:e.limit,consolidate:e.consolidate,includeBreadcrumb:e.includeBreadcrumb,withContext:e.withContext},params:{},body:{}});var nm=e=>({path:`/v1/files/${encodeURIComponent(e.id)}/passages`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,limit:e.limit},params:{id:e.id},body:{}});var om=e=>({path:`/v1/files/${encodeURIComponent(e.id)}/passages`,headers:{},query:{},params:{id:e.id},body:{passages:e.passages}});var pm=e=>({path:"/v1/files/tags",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{},body:{}});var cm=e=>({path:`/v1/files/tags/${encodeURIComponent(e.tag)}/values`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{tag:e.tag},body:{}});var lm=e=>({path:"/v1/files/knowledge-bases",headers:{},query:{},params:{},body:{name:e.name,description:e.description,tags:e.tags}});var ym=e=>({path:`/v1/files/knowledge-bases/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Rm=e=>({path:`/v1/files/knowledge-bases/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{name:e.name,description:e.description,tags:e.tags}});var hm=e=>({path:"/v1/files/knowledge-bases",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,tags:e.tags},params:{},body:{}});var Tt=class{constructor(t,s={}){this.httpClient=t;this.props=s}upsertFile=async t=>{let{path:s,headers:n,query:a,body:o}=Vy(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteFile=async t=>{let{path:s,headers:n,query:a,body:o}=Ky(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFiles=async t=>{let{path:s,headers:n,query:a,body:o}=zy(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getFile=async t=>{let{path:s,headers:n,query:a,body:o}=jy(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateFileMetadata=async t=>{let{path:s,headers:n,query:a,body:o}=Zy(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};copyFile=async t=>{let{path:s,headers:n,query:a,body:o}=em(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};searchFiles=async t=>{let{path:s,headers:n,query:a,body:o}=rm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFilePassages=async t=>{let{path:s,headers:n,query:a,body:o}=nm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setFilePassages=async t=>{let{path:s,headers:n,query:a,body:o}=om(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFileTags=async t=>{let{path:s,headers:n,query:a,body:o}=pm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFileTagValues=async t=>{let{path:s,headers:n,query:a,body:o}=cm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createKnowledgeBase=async t=>{let{path:s,headers:n,query:a,body:o}=lm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteKnowledgeBase=async t=>{let{path:s,headers:n,query:a,body:o}=ym(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateKnowledgeBase=async t=>{let{path:s,headers:n,query:a,body:o}=Rm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listKnowledgeBases=async t=>{let{path:s,headers:n,query:a,body:o}=hm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})}};function N(e){let t=e?.response?.data;return t?zn(t):zn(e)}var wt=async(e,{key:t,index:s,tags:n,contentType:a,accessPolicies:o,content:i,url:p,indexing:u,expiresAt:r,metadata:y,publicContentImmediatelyAccessible:x})=>{if(p&&i)throw new ie("Cannot provide both content and URL, please provide only one of them");if(p&&(i=await new W.HttpClient().get(p,{responseType:"arraybuffer"}).then(L=>L.data).catch(L=>{throw new ie(`Failed to download file from provided URL: ${L.message}`,L)})),!i)throw new ie("No content was provided for the file");let m,k;if(typeof i=="string"){let I=new TextEncoder().encode(i);m=I,k=I.byteLength}else if(i instanceof Uint8Array)m=i,k=m.byteLength;else if(i instanceof ArrayBuffer)m=i,k=m.byteLength;else if(i instanceof Blob)m=i,k=i.size;else throw new ie("The provided content is not supported");let{file:P}=await e.upsertFile({key:t,tags:n,index:s,accessPolicies:o,contentType:a,metadata:y,size:k,expiresAt:r,indexing:u,publicContentImmediatelyAccessible:x}),q={"Content-Type":P.contentType};x&&(q["x-amz-tagging"]="public=true");try{await new W.HttpClient().put(P.uploadUrl,m,{headers:q})}catch(L){let I=L instanceof Error?L:new Error(String(L));throw new ie(`Failed to upload file: ${I.message}`,I,P)}return{file:{...P,size:k}}};var Jn=class extends Tt{config;constructor(t){let s=$.getClientConfig(t),n=W.createHttpClient(s);super(n,{toApiError:z.toApiError}),t.retry&&(n.retry=t.retry),this.config=s}get list(){return{files:t=>new R.AsyncCollection(({nextToken:s})=>this.listFiles({nextToken:s,...t}).then(n=>({...n,items:n.files}))),filePassages:t=>new R.AsyncCollection(({nextToken:s})=>this.listFilePassages({nextToken:s,...t}).then(n=>({...n,items:n.passages}))),fileTags:t=>new R.AsyncCollection(({nextToken:s})=>this.listFileTags({nextToken:s,...t}).then(n=>({...n,items:n.tags}))),fileTagValues:t=>new R.AsyncCollection(({nextToken:s})=>this.listFileTagValues({nextToken:s,...t}).then(n=>({...n,items:n.values}))),knowledgeBases:t=>new R.AsyncCollection(({nextToken:s})=>this.listKnowledgeBases({nextToken:s,...t}).then(n=>({...n,items:n.knowledgeBases})))}}async uploadFile(t){return await wt(this,t)}};var sR={};te(sR,{Client:()=>xa});var gC={getRandomValues:e=>new Uint8Array(e.map(()=>Math.floor(Math.random()*256)))},yC=typeof globalThis.crypto<"u"&&typeof globalThis.crypto.getRandomValues=="function"?globalThis.crypto:gC,E=class e extends Error{constructor(s,n,a,o,i,p,u){super(o);this.code=s;this.description=n;this.type=a;this.message=o;this.error=i;this.id=p;this.metadata=u;this.id||(this.id=e.generateId())}isApiError=!0;format(){return`[${this.type}] ${this.message} (Error ID: ${this.id})`}toJSON(){return{id:this.id,code:this.code,type:this.type,message:this.message,metadata:this.metadata}}static generateId(){let s=this.getPrefix(),n=new Date().toISOString().replace(/[\-:TZ]/g,"").split(".")[0],a=4,o=Array.from(yC.getRandomValues(new Uint8Array(a))).map(i=>i.toString(16).padStart(2,"0")).join("").toUpperCase();return`${s}_${n}x${o}`}static getPrefix(){return typeof window<"u"&&typeof window.document<"u"?"err_bwsr":"err"}},mC=e=>typeof e=="object"&&!Array.isArray(e)&&e!==null,RC=e=>e instanceof E||mC(e)&&e.isApiError===!0,Ae=class extends E{constructor(t,s,n,a){super(500,"An unknown error occurred","Unknown",t,s,n,a)}},jn=class extends E{constructor(t,s,n,a){super(500,"An internal error occurred","Internal",t,s,n,a)}},Yn=class extends E{constructor(t,s,n,a){super(401,"The request requires to be authenticated.","Unauthorized",t,s,n,a)}},Zn=class extends E{constructor(t,s,n,a){super(403,"The requested action can't be peform by this resource.","Forbidden",t,s,n,a)}},Xn=class extends E{constructor(t,s,n,a){super(413,"The request payload is too large.","PayloadTooLarge",t,s,n,a)}},ea=class extends E{constructor(t,s,n,a){super(400,"The request payload is invalid.","InvalidPayload",t,s,n,a)}},ta=class extends E{constructor(t,s,n,a){super(415,"The request is invalid because the content-type is not supported.","UnsupportedMediaType",t,s,n,a)}},ra=class extends E{constructor(t,s,n,a){super(405,"The requested method does not exist.","MethodNotFound",t,s,n,a)}},sa=class extends E{constructor(t,s,n,a){super(404,"The requested resource does not exist.","ResourceNotFound",t,s,n,a)}},na=class extends E{constructor(t,s,n,a){super(400,"The provided JSON schema is invalid.","InvalidJsonSchema",t,s,n,a)}},aa=class extends E{constructor(t,s,n,a){super(400,"The provided data doesn't respect the provided JSON schema.","InvalidDataFormat",t,s,n,a)}},oa=class extends E{constructor(t,s,n,a){super(400,"The provided identifier is not valid. An identifier must start with a lowercase letter, be between 2 and 100 characters long and use only alphanumeric characters.","InvalidIdentifier",t,s,n,a)}},ia=class extends E{constructor(t,s,n,a){super(409,"The resource is related with a different resource that the one referenced in the request. This is usually caused when providing two resource identifiers that aren't linked together.","RelationConflict",t,s,n,a)}},pa=class extends E{constructor(t,s,n,a){super(409,"The resource cannot be deleted because it's referenced by another resource","ReferenceConstraint",t,s,n,a)}},ua=class extends E{constructor(t,s,n,a){super(409,"The resource is current locked and cannot be operated on until the lock is released.","ResourceLockedConflict",t,s,n,a)}},ca=class extends E{constructor(t,s,n,a){super(410,"The requested resource is no longer available.","ResourceGone",t,s,n,a)}},da=class extends E{constructor(t,s,n,a){super(400,"The provided resource reference is missing. This is usually caused when providing an invalid id inside the payload of a request.","ReferenceNotFound",t,s,n,a)}},la=class extends E{constructor(t,s,n,a){super(400,"The provided query is invalid. This is usually caused when providing an invalid parameter for querying a resource.","InvalidQuery",t,s,n,a)}},ga=class extends E{constructor(t,s,n,a){super(400,"An error happened during the execution of a runtime (bot or integration).","Runtime",t,s,n,a)}},ya=class extends E{constructor(t,s,n,a){super(409,"The record attempted to be created already exists.","AlreadyExists",t,s,n,a)}},ma=class extends E{constructor(t,s,n,a){super(429,"The request has been rate limited.","RateLimited",t,s,n,a)}},Ra=class extends E{constructor(t,s,n,a){super(402,"A payment is required to perform this request.","PaymentRequired",t,s,n,a)}},qa=class extends E{constructor(t,s,n,a){super(403,"The request exceeds the allowed quota. Quotas are a soft limit that can be increased.","QuotaExceeded",t,s,n,a)}},ha=class extends E{constructor(t,s,n,a){super(413,"The request exceeds the allowed limit. Limits are a hard limit that cannot be increased.","LimitExceeded",t,s,n,a)}},ba=class extends E{constructor(t,s,n,a){super(400,"Request payload contains breaking changes which is not allowed for this resource without a version increment.","BreakingChanges",t,s,n,a)}},fa=class extends E{constructor(t,s,n,a){super(504,"The operation timed out.","OperationTimeout",t,s,n,a)}},qC={Unknown:Ae,Internal:jn,Unauthorized:Yn,Forbidden:Zn,PayloadTooLarge:Xn,InvalidPayload:ea,UnsupportedMediaType:ta,MethodNotFound:ra,ResourceNotFound:sa,InvalidJsonSchema:na,InvalidDataFormat:aa,InvalidIdentifier:oa,RelationConflict:ia,ReferenceConstraint:pa,ResourceLockedConflict:ua,ResourceGone:ca,ReferenceNotFound:da,InvalidQuery:la,Runtime:ga,AlreadyExists:ya,RateLimited:ma,PaymentRequired:Ra,QuotaExceeded:qa,LimitExceeded:ha,BreakingChanges:ba,OperationTimeout:fa},Ia=e=>RC(e)?e:e instanceof Error?new Ae(e.message,e):typeof e=="string"?new Ae(e):hC(e);function hC(e){if(typeof e=="object"&&"code"in e&&"type"in e&&"id"in e&&"message"in e&&typeof e.type=="string"&&typeof e.message=="string"){let t=qC[e.type];return t?new t(e.message,void 0,e.id||"UNKNOWN",e.metadata):new Ae(`An unclassified API error occurred: ${e.message} (Type: ${e.type}, Code: ${e.code})`)}return new Ae("An invalid error occurred: "+JSON.stringify(e))}var xm=Te(xe()),bC=e=>e[1]!==void 0,D=e=>{let{method:t,path:s,query:n,headers:a,body:o}=e,i=Object.entries(a).filter(bC),p=Object.fromEntries(i),u=xm.default.stringify(n,{encode:!0,arrayFormat:"repeat",allowDots:!0}),r=u?[s,u].join("?"):s,y=["put","post","delete","patch"].includes(t.toLowerCase())?o:void 0;return{method:t,url:r,headers:p,data:y}};var km=e=>({path:"/v1/tables",headers:{},query:{tags:e.tags},params:{},body:{}});var vm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{}});var Cm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{factor:e.factor,frozen:e.frozen,keyColumn:e.keyColumn,schema:e.schema,tags:e.tags,isComputeEnabled:e.isComputeEnabled}});var Tm=e=>({path:"/v1/tables",headers:{},query:{},params:{},body:{name:e.name,factor:e.factor,frozen:e.frozen,keyColumn:e.keyColumn,schema:e.schema,tags:e.tags,isComputeEnabled:e.isComputeEnabled}});var Um=e=>({path:`/v1/tables/${encodeURIComponent(e.sourceTableId)}/duplicate`,headers:{},query:{},params:{sourceTableId:e.sourceTableId},body:{tableName:e.tableName,schemaOnly:e.schemaOnly,factor:e.factor}});var Sm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/export`,headers:{},query:{format:e.format,compress:e.compress},params:{table:e.table},body:{}});var Lm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/jobs`,headers:{},query:{},params:{table:e.table},body:{}});var _m=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/import`,headers:{},query:{},params:{table:e.table},body:{fileId:e.fileId}});var Qm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{name:e.name,frozen:e.frozen,keyColumn:e.keyColumn,schema:e.schema,tags:e.tags,isComputeEnabled:e.isComputeEnabled,factor:e.factor}});var Fm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/column`,headers:{},query:{},params:{table:e.table},body:{name:e.name,newName:e.newName}});var Om=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{}});var Nm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/row`,headers:{},query:{id:e.id},params:{table:e.table},body:{}});var $m=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows/find`,headers:{},query:{},params:{table:e.table},body:{limit:e.limit,offset:e.offset,filter:e.filter,group:e.group,search:e.search,select:e.select,orderBy:e.orderBy,orderDirection:e.orderDirection}});var Jm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows`,headers:{},query:{},params:{table:e.table},body:{rows:e.rows,waitComputed:e.waitComputed}});var Ym=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows/delete`,headers:{},query:{},params:{table:e.table},body:{ids:e.ids,filter:e.filter,deleteAllRows:e.deleteAllRows}});var Xm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows`,headers:{},query:{},params:{table:e.table},body:{rows:e.rows,waitComputed:e.waitComputed}});var tR=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows/upsert`,headers:{},query:{},params:{table:e.table},body:{rows:e.rows,keyColumn:e.keyColumn,waitComputed:e.waitComputed}});var Ut=class{constructor(t,s={}){this.httpClient=t;this.props=s}listTables=async t=>{let{path:s,headers:n,query:a,body:o}=km(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getTable=async t=>{let{path:s,headers:n,query:a,body:o}=vm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateTable=async t=>{let{path:s,headers:n,query:a,body:o}=Cm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createTable=async t=>{let{path:s,headers:n,query:a,body:o}=Tm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};duplicateTable=async t=>{let{path:s,headers:n,query:a,body:o}=Um(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};exportTable=async t=>{let{path:s,headers:n,query:a,body:o}=Sm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getTableJobs=async t=>{let{path:s,headers:n,query:a,body:o}=Lm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};importTable=async t=>{let{path:s,headers:n,query:a,body:o}=_m(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateTable=async t=>{let{path:s,headers:n,query:a,body:o}=Qm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};renameTableColumn=async t=>{let{path:s,headers:n,query:a,body:o}=Fm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteTable=async t=>{let{path:s,headers:n,query:a,body:o}=Om(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getTableRow=async t=>{let{path:s,headers:n,query:a,body:o}=Nm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};findTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=$m(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=Jm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=Ym(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=Xm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};upsertTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=tR(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})}};function M(e){let t=e?.response?.data;return t?Ia(t):Ia(e)}var xa=class extends Ut{config;constructor(t){let s=$.getClientConfig(t),n=W.createHttpClient(s);super(n,{toApiError:z.toApiError}),t.retry&&(n.retry=t.retry),this.config=s}};var nR=Te(xe()),IC=e=>e[1]!==void 0,c=e=>{let{method:t,path:s,query:n,headers:a,body:o}=e,i=Object.entries(a).filter(IC),p=Object.fromEntries(i),u=nR.default.stringify(n,{encode:!0,arrayFormat:"repeat",allowDots:!0}),r=u?[s,u].join("?"):s,y=["put","post","delete","patch"].includes(t.toLowerCase())?o:void 0;return{method:t,url:r,headers:p,data:y}};var aR=e=>({path:"/v1/chat/conversations",headers:{},query:{},params:{},body:{channel:e.channel,tags:e.tags,integrationName:e.integrationName,properties:e.properties}});var iR=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var uR=e=>({path:"/v1/chat/conversations",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,sortField:e.sortField,sortDirection:e.sortDirection,tags:e.tags,participantIds:e.participantIds,integrationName:e.integrationName,channel:e.channel,afterDate:e.afterDate,beforeDate:e.beforeDate,minMessageCount:e.minMessageCount,maxMessageCount:e.maxMessageCount},params:{},body:{}});var dR=e=>({path:"/v1/chat/conversations/get-or-create",headers:{},query:{},params:{},body:{channel:e.channel,tags:e.tags,integrationName:e.integrationName,properties:e.properties,discriminateByTags:e.discriminateByTags}});var gR=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{currentTaskId:e.currentTaskId,tags:e.tags,properties:e.properties}});var mR=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var qR=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var bR=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants`,headers:{},query:{},params:{id:e.id},body:{userId:e.userId}});var IR=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants/${encodeURIComponent(e.userId)}`,headers:{},query:{},params:{id:e.id,userId:e.userId},body:{}});var kR=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants/${encodeURIComponent(e.userId)}`,headers:{},query:{},params:{id:e.id,userId:e.userId},body:{}});var vR=e=>({path:"/v1/chat/events",headers:{},query:{},params:{},body:{type:e.type,payload:e.payload,schedule:e.schedule,conversationId:e.conversationId,userId:e.userId,workflowId:e.workflowId,messageId:e.messageId}});var CR=e=>({path:`/v1/chat/events/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var TR=e=>({path:"/v1/chat/events",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,type:e.type,conversationId:e.conversationId,userId:e.userId,messageId:e.messageId,workflowId:e.workflowId,status:e.status},params:{},body:{}});var UR=e=>({path:`/v1/chat/events/scheduled/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var SR=e=>({path:"/v1/chat/messages",headers:{},query:{},params:{},body:{payload:e.payload,userId:e.userId,conversationId:e.conversationId,type:e.type,tags:e.tags,schedule:e.schedule,origin:e.origin}});var LR=e=>({path:"/v1/chat/messages/get-or-create",headers:{},query:{},params:{},body:{payload:e.payload,userId:e.userId,conversationId:e.conversationId,type:e.type,tags:e.tags,schedule:e.schedule,origin:e.origin,discriminateByTags:e.discriminateByTags}});var _R=e=>({path:`/v1/chat/messages/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var QR=e=>({path:`/v1/chat/messages/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{tags:e.tags,payload:e.payload}});var FR=e=>({path:"/v1/chat/messages",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,conversationId:e.conversationId,tags:e.tags,afterDate:e.afterDate,beforeDate:e.beforeDate},params:{},body:{}});var OR=e=>({path:`/v1/chat/messages/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var NR=e=>({path:"/v1/chat/initialize-incoming-message",headers:{},query:{},params:{},body:{userId:e.userId,user:e.user,conversationId:e.conversationId,conversation:e.conversation,message:e.message}});var $R=e=>({path:"/v1/chat/messages/import-messages",headers:{},query:{},params:{},body:{messages:e.messages}});var JR=e=>({path:"/v1/chat/users",headers:{},query:{},params:{},body:{tags:e.tags,integrationName:e.integrationName,name:e.name,pictureUrl:e.pictureUrl,properties:e.properties,attributes:e.attributes}});var YR=e=>({path:`/v1/chat/users/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var XR=e=>({path:"/v1/chat/users",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,conversationId:e.conversationId,tags:e.tags,afterDate:e.afterDate,beforeDate:e.beforeDate,rangeField:e.rangeField,sortField:e.sortField,sortDirection:e.sortDirection},params:{},body:{}});var tq=e=>({path:"/v1/chat/users/get-or-create",headers:{},query:{},params:{},body:{tags:e.tags,integrationName:e.integrationName,name:e.name,pictureUrl:e.pictureUrl,properties:e.properties,attributes:e.attributes,discriminateByTags:e.discriminateByTags}});var sq=e=>({path:`/v1/chat/users/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{tags:e.tags,name:e.name,pictureUrl:e.pictureUrl,attributes:e.attributes,properties:e.properties}});var aq=e=>({path:`/v1/chat/users/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var iq=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}/expiry`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{expiry:e.expiry}});var uq=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{}});var dq=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{payload:e.payload,expiry:e.expiry}});var gq=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}/get-or-set`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{payload:e.payload,expiry:e.expiry}});var mq=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{payload:e.payload,expiry:e.expiry}});var qq=e=>({path:"/v1/chat/actions",headers:{},query:{},params:{},body:{type:e.type,input:e.input}});var bq=e=>({path:"/v1/chat/integration/identifiers",headers:{},query:{value:e.value},params:{},body:{}});var Iq=e=>({path:"/v1/chat/integration/identifiers/availability",headers:{},query:{value:e.value},params:{},body:{}});var kq=e=>({path:"/v1/chat/integrations/configure",headers:{},query:{},params:{},body:{identifier:e.identifier,scheduleRegisterCall:e.scheduleRegisterCall,sandboxIdentifiers:e.sandboxIdentifiers}});var vq=e=>({path:"/v1/chat/workflows",headers:{},query:{},params:{},body:{name:e.name,input:e.input,parentWorkflowId:e.parentWorkflowId,conversationId:e.conversationId,userId:e.userId,timeoutAt:e.timeoutAt,tags:e.tags,status:e.status,eventId:e.eventId}});var Cq=e=>({path:`/v1/chat/workflows/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Tq=e=>({path:`/v1/chat/workflows/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{output:e.output,timeoutAt:e.timeoutAt,status:e.status,failureReason:e.failureReason,tags:e.tags,userId:e.userId,eventId:e.eventId}});var Uq=e=>({path:`/v1/chat/workflows/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Sq=e=>({path:"/v1/chat/workflows",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,tags:e.tags,conversationId:e.conversationId,userId:e.userId,parentWorkflowId:e.parentWorkflowId,statuses:e.statuses,name:e.name},params:{},body:{}});var Lq=e=>({path:"/v1/chat/workflows/get-or-create",headers:{},query:{},params:{},body:{name:e.name,input:e.input,parentWorkflowId:e.parentWorkflowId,conversationId:e.conversationId,userId:e.userId,timeoutAt:e.timeoutAt,tags:e.tags,status:e.status,eventId:e.eventId,discriminateByTags:e.discriminateByTags,discriminateByStatusGroup:e.discriminateByStatusGroup}});var _q=e=>({path:`/v1/chat/tags/${encodeURIComponent(e.key)}/values`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,type:e.type},params:{key:e.key},body:{}});var Qq=e=>({path:"/v1/chat/analytics",headers:{},query:{},params:{},body:{name:e.name,count:e.count}});var Fq=e=>({path:"/v1/chat/observations",headers:{},query:{},params:{},body:{id:e.id,name:e.name,data:e.data,messageId:e.messageId,eventId:e.eventId,conversationId:e.conversationId,userId:e.userId,errorId:e.errorId,traceId:e.traceId}});var Oq=e=>({path:"/v1/admin/helper/vrl",headers:{},query:{},params:{},body:{data:e.data,script:e.script}});var Nq=e=>({path:"/v1/admin/account/me",headers:{},query:{},params:{},body:{}});var $q=e=>({path:"/v1/admin/account/me",headers:{},query:{},params:{},body:{displayName:e.displayName,profilePicture:e.profilePicture,refresh:e.refresh}});var Jq=e=>({path:"/v1/admin/account/me",headers:{},query:{},params:{},body:{}});var Yq=e=>({path:"/v1/admin/account/pats",headers:{},query:{},params:{},body:{}});var Xq=e=>({path:"/v1/admin/account/pats",headers:{},query:{},params:{},body:{note:e.note}});var th=e=>({path:`/v1/admin/account/pats/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var sh=e=>({path:`/v1/admin/account/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{value:e.value}});var ah=e=>({path:`/v1/admin/account/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{}});var ih=e=>({path:"/v1/admin/hub/integrations",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,limit:e.limit,name:e.name,version:e.version,interfaceId:e.interfaceId,interfaceName:e.interfaceName,installedByBotId:e.installedByBotId,verificationStatus:e.verificationStatus,search:e.search,sortBy:e.sortBy,direction:e.direction},params:{},body:{}});var uh=e=>({path:`/v1/admin/hub/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var dh=e=>({path:`/v1/admin/hub/integrations/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var gh=e=>({path:"/v1/admin/hub/plugins",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var mh=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var qh=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.id)}/dereferenced`,headers:{},query:{interfaces:e.interfaces},params:{id:e.id},body:{}});var bh=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var Ih=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.id)}/code/${encodeURIComponent(e.platform)}`,headers:{},query:{},params:{id:e.id,platform:e.platform},body:{}});var kh=e=>({path:"/v1/admin/hub/interfaces",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var vh=e=>({path:`/v1/admin/hub/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Ch=e=>({path:`/v1/admin/hub/interfaces/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var Th=e=>({path:"/v1/admin/bots",headers:{},query:{},params:{},body:{states:e.states,events:e.events,recurringEvents:e.recurringEvents,actions:e.actions,configuration:e.configuration,user:e.user,conversation:e.conversation,message:e.message,tags:e.tags,maxExecutionTime:e.maxExecutionTime,subscriptions:e.subscriptions,code:e.code,name:e.name,description:e.description,medias:e.medias,url:e.url,secrets:e.secrets,dev:e.dev,type:e.type,moduleFormat:e.moduleFormat}});var Uh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{url:e.url,authentication:e.authentication,configuration:e.configuration,maxExecutionTime:e.maxExecutionTime,blocked:e.blocked,alwaysAlive:e.alwaysAlive,tags:e.tags,user:e.user,message:e.message,conversation:e.conversation,events:e.events,actions:e.actions,states:e.states,recurringEvents:e.recurringEvents,integrations:e.integrations,plugins:e.plugins,subscriptions:e.subscriptions,code:e.code,name:e.name,description:e.description,medias:e.medias,secrets:e.secrets,layers:e.layers,type:e.type,moduleFormat:e.moduleFormat}});var Sh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/signing-secrets/rotate`,headers:{},query:{},params:{id:e.id},body:{}});var Lh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/transfer`,headers:{},query:{},params:{id:e.id},body:{targetWorkspaceId:e.targetWorkspaceId}});var _h=e=>({path:"/v1/admin/bots",headers:{},query:{dev:e.dev,tags:e.tags,integrationNames:e.integrationNames,pluginNames:e.pluginNames,nextToken:e.nextToken,pageSize:e.pageSize,sortField:e.sortField,sortDirection:e.sortDirection},params:{},body:{}});var Qh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Fh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Oh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/logs`,headers:{},query:{timeStart:e.timeStart,timeEnd:e.timeEnd,level:e.level,userId:e.userId,workflowId:e.workflowId,conversationId:e.conversationId,messageContains:e.messageContains,nextToken:e.nextToken},params:{id:e.id},body:{}});var Nh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/webchat`,headers:{},query:{type:e.type},params:{id:e.id},body:{}});var $h=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/analytics`,headers:{},query:{startDate:e.startDate,endDate:e.endDate},params:{id:e.id},body:{}});var Jh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/action-runs`,headers:{},query:{integrationName:e.integrationName,timestampFrom:e.timestampFrom,timestampUntil:e.timestampUntil,nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var Yh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues/${encodeURIComponent(e.issueId)}`,headers:{},query:{},params:{id:e.id,issueId:e.issueId},body:{}});var Xh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var tb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues/${encodeURIComponent(e.issueId)}`,headers:{},query:{},params:{id:e.id,issueId:e.issueId},body:{}});var sb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues/${encodeURIComponent(e.issueId)}/events`,headers:{},query:{},params:{id:e.id,issueId:e.issueId},body:{}});var ab=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions`,headers:{},query:{},params:{id:e.id},body:{}});var ib=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions/${encodeURIComponent(e.versionId)}`,headers:{},query:{},params:{id:e.id,versionId:e.versionId},body:{}});var ub=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/bot-json`,headers:{},query:{},params:{id:e.id},body:{}});var db=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/publish-from-bot-json`,headers:{},query:{},params:{id:e.id},body:{botJson:e.botJson}});var gb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions`,headers:{},query:{},params:{id:e.id},body:{name:e.name,description:e.description}});var mb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions/deploy`,headers:{},query:{},params:{id:e.id},body:{versionId:e.versionId}});var qb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/shareable-id`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var bb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/shareable-id`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var Ib=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/shareable-id`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var kb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/sandboxed-conversations`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var vb=e=>({path:"/v1/admin/bots/baks",headers:{},query:{botId:e.botId},params:{},body:{}});var Cb=e=>({path:"/v1/admin/bots/baks",headers:{},query:{},params:{},body:{botId:e.botId,note:e.note}});var Tb=e=>({path:`/v1/admin/bots/baks/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Ub=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/allowlist`,headers:{},query:{},params:{botId:e.botId},body:{}});var Sb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/allowlist`,headers:{},query:{},params:{botId:e.botId},body:{setting:e.setting,users:e.users}});var Lb=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/migrate-to-v4`,headers:{},query:{},params:{id:e.id},body:{}});var _b=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/billing/invoices`,headers:{},query:{},params:{id:e.id},body:{}});var Qb=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/billing/upcoming-invoice`,headers:{},query:{},params:{id:e.id},body:{}});var Fb=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/billing/invoices/charge-unpaid`,headers:{},query:{},params:{id:e.id},body:{invoiceIds:e.invoiceIds}});var Ob=e=>({path:"/v1/admin/workspaces",headers:{},query:{},params:{},body:{name:e.name,billingVersion:e.billingVersion}});var Nb=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/public`,headers:{},query:{},params:{id:e.id},body:{}});var $b=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Jb=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/usages`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var Yb=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/usages/by-bot`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var Xb=e=>({path:"/v1/admin/workspaces/usages/quota-completion",headers:{},query:{},params:{},body:{}});var tf=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/quota`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var sf=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/quotas`,headers:{},query:{period:e.period},params:{id:e.id},body:{}});var af=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{name:e.name,spendingLimit:e.spendingLimit,about:e.about,profilePicture:e.profilePicture,contactEmail:e.contactEmail,website:e.website,socialAccounts:e.socialAccounts,isPublic:e.isPublic,handle:e.handle}});var pf=e=>({path:"/v1/admin/workspaces/handle-availability",headers:{},query:{},params:{},body:{handle:e.handle}});var cf=e=>({path:"/v1/admin/workspaces",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,handle:e.handle},params:{},body:{}});var lf=e=>({path:"/v1/admin/workspaces/public",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,workspaceIds:e.workspaceIds,search:e.search},params:{},body:{}});var yf=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Rf=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/audit-records`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var hf=e=>({path:`/v1/admin/workspaces/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{value:e.value}});var ff=e=>({path:`/v1/admin/workspaces/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{}});var xf=e=>({path:"/v1/admin/workspace-members",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{},body:{}});var Pf=e=>({path:"/v1/admin/workspace-members/me",headers:{},query:{},params:{},body:{}});var Af=e=>({path:`/v1/admin/workspace-members/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Bf=e=>({path:"/v1/admin/workspace-members",headers:{},query:{},params:{},body:{email:e.email,role:e.role,sendEmail:e.sendEmail}});var wf=e=>({path:`/v1/admin/workspace-members/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{role:e.role}});var Gf=e=>({path:"/v1/admin/integrations/iaks",headers:{},query:{integrationId:e.integrationId},params:{},body:{}});var Ef=e=>({path:"/v1/admin/integrations/iaks",headers:{},query:{},params:{},body:{integrationId:e.integrationId,note:e.note}});var Wf=e=>({path:`/v1/admin/integrations/iaks/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Hf=e=>({path:"/v1/admin/integrations",headers:{},query:{},params:{},body:{name:e.name,version:e.version,configuration:e.configuration,configurations:e.configurations,states:e.states,events:e.events,actions:e.actions,entities:e.entities,identifier:e.identifier,channels:e.channels,user:e.user,interfaces:e.interfaces,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,secrets:e.secrets,code:e.code,url:e.url,dev:e.dev,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,layers:e.layers,attributes:e.attributes}});var Df=e=>({path:"/v1/admin/integrations/validate",headers:{},query:{},params:{},body:{name:e.name,version:e.version,configuration:e.configuration,configurations:e.configurations,states:e.states,events:e.events,actions:e.actions,entities:e.entities,identifier:e.identifier,channels:e.channels,user:e.user,interfaces:e.interfaces,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,secrets:e.secrets,code:e.code,url:e.url,dev:e.dev,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,layers:e.layers,attributes:e.attributes}});var Mf=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{configuration:e.configuration,configurations:e.configurations,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,channels:e.channels,maxExecutionTime:e.maxExecutionTime,identifier:e.identifier,actions:e.actions,events:e.events,states:e.states,user:e.user,entities:e.entities,interfaces:e.interfaces,attributes:e.attributes,secrets:e.secrets,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,url:e.url,public:e.public,visibility:e.visibility,layers:e.layers}});var Vf=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}/signing-secrets/rotate`,headers:{},query:{},params:{id:e.id},body:{}});var Kf=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}/validate`,headers:{},query:{},params:{id:e.id},body:{configuration:e.configuration,configurations:e.configurations,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,channels:e.channels,maxExecutionTime:e.maxExecutionTime,identifier:e.identifier,actions:e.actions,events:e.events,states:e.states,user:e.user,entities:e.entities,interfaces:e.interfaces,attributes:e.attributes,secrets:e.secrets,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,url:e.url,public:e.public,visibility:e.visibility,layers:e.layers}});var zf=e=>({path:"/v1/admin/integrations",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,limit:e.limit,name:e.name,version:e.version,interfaceId:e.interfaceId,interfaceName:e.interfaceName,installedByBotId:e.installedByBotId,verificationStatus:e.verificationStatus,search:e.search,sortBy:e.sortBy,direction:e.direction,visibility:e.visibility,dev:e.dev},params:{},body:{}});var jf=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Zf=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}/logs`,headers:{},query:{timeStart:e.timeStart,timeEnd:e.timeEnd,level:e.level,userId:e.userId,conversationId:e.conversationId,messageContains:e.messageContains,nextToken:e.nextToken},params:{id:e.id},body:{}});var eI=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var rI=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var nI=e=>({path:"/v1/admin/integrations/request-verification",headers:{},query:{},params:{},body:{integrationId:e.integrationId}});var oI=e=>({path:"/v1/admin/interfaces",headers:{},query:{},params:{},body:{name:e.name,version:e.version,entities:e.entities,events:e.events,actions:e.actions,channels:e.channels,nameTemplate:e.nameTemplate,sdkVersion:e.sdkVersion,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,attributes:e.attributes}});var pI=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var cI=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var lI=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{entities:e.entities,events:e.events,actions:e.actions,channels:e.channels,nameTemplate:e.nameTemplate,sdkVersion:e.sdkVersion,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,attributes:e.attributes}});var yI=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var RI=e=>({path:"/v1/admin/interfaces",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var hI=e=>({path:"/v1/admin/plugins",headers:{},query:{},params:{},body:{name:e.name,version:e.version,configuration:e.configuration,states:e.states,events:e.events,actions:e.actions,user:e.user,conversation:e.conversation,message:e.message,sdkVersion:e.sdkVersion,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,dependencies:e.dependencies,attributes:e.attributes}});var fI=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var xI=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}/dereferenced`,headers:{},query:{interfaces:e.interfaces},params:{id:e.id},body:{}});var PI=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var AI=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{configuration:e.configuration,states:e.states,events:e.events,actions:e.actions,user:e.user,conversation:e.conversation,message:e.message,sdkVersion:e.sdkVersion,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,dependencies:e.dependencies,attributes:e.attributes}});var BI=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var wI=e=>({path:"/v1/admin/plugins",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var GI=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}/code/${encodeURIComponent(e.platform)}`,headers:{},query:{},params:{id:e.id,platform:e.platform},body:{}});var EI=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var WI=e=>({path:"/v1/admin/usages/multiple",headers:{},query:{types:e.types,ids:e.ids,period:e.period},params:{},body:{}});var HI=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}/history`,headers:{},query:{type:e.type},params:{id:e.id},body:{}});var DI=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}/activity`,headers:{},query:{type:e.type,timestampFrom:e.timestampFrom,timestampUntil:e.timestampUntil,nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var MI=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}/daily-activity`,headers:{},query:{type:e.type,dateFrom:e.dateFrom,dateUntil:e.dateUntil,nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var VI=e=>({path:"/v1/admin/quotas/ai-spend",headers:{},query:{},params:{},body:{monthlySpendingLimit:e.monthlySpendingLimit}});var KI=e=>({path:"/v1/admin/activities",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,taskId:e.taskId,botId:e.botId},params:{},body:{}});var zI=e=>({path:"/v1/admin/introspect",headers:{},query:{},params:{},body:{botId:e.botId}});var jI=e=>({path:"/v1/files",headers:{},query:{},params:{},body:{key:e.key,tags:e.tags,size:e.size,index:e.index,indexing:e.indexing,accessPolicies:e.accessPolicies,contentType:e.contentType,expiresAt:e.expiresAt,publicContentImmediatelyAccessible:e.publicContentImmediatelyAccessible,metadata:e.metadata}});var ZI=e=>({path:`/v1/files/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var ex=e=>({path:"/v1/files",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,sortField:e.sortField,sortDirection:e.sortDirection,tags:e.tags,ids:e.ids,indexed:e.indexed},params:{},body:{}});var rx=e=>({path:`/v1/files/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var nx=e=>({path:`/v1/files/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{metadata:e.metadata,tags:e.tags,accessPolicies:e.accessPolicies,expiresAt:e.expiresAt}});var ox=e=>({path:`/v1/files/${encodeURIComponent(e.idOrKey)}/${encodeURIComponent(e.destinationKey)}`,headers:{"x-destination-bot-id":e["x-destination-bot-id"]},query:{},params:{idOrKey:e.idOrKey,destinationKey:e.destinationKey},body:{overwrite:e.overwrite}});var px=e=>({path:"/v1/files/search",headers:{},query:{tags:e.tags,query:e.query,contextDepth:e.contextDepth,limit:e.limit,consolidate:e.consolidate,includeBreadcrumb:e.includeBreadcrumb,withContext:e.withContext},params:{},body:{}});var cx=e=>({path:`/v1/files/${encodeURIComponent(e.id)}/passages`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,limit:e.limit},params:{id:e.id},body:{}});var lx=e=>({path:`/v1/files/${encodeURIComponent(e.id)}/passages`,headers:{},query:{},params:{id:e.id},body:{passages:e.passages}});var yx=e=>({path:"/v1/files/tags",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{},body:{}});var Rx=e=>({path:`/v1/files/tags/${encodeURIComponent(e.tag)}/values`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{tag:e.tag},body:{}});var hx=e=>({path:"/v1/files/knowledge-bases",headers:{},query:{},params:{},body:{name:e.name,description:e.description,tags:e.tags}});var fx=e=>({path:`/v1/files/knowledge-bases/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var xx=e=>({path:`/v1/files/knowledge-bases/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{name:e.name,description:e.description,tags:e.tags}});var Px=e=>({path:"/v1/files/knowledge-bases",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,tags:e.tags},params:{},body:{}});var Ax=e=>({path:"/v1/tables",headers:{},query:{tags:e.tags},params:{},body:{}});var Bx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{}});var wx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{factor:e.factor,frozen:e.frozen,keyColumn:e.keyColumn,schema:e.schema,tags:e.tags,isComputeEnabled:e.isComputeEnabled}});var Gx=e=>({path:"/v1/tables",headers:{},query:{},params:{},body:{name:e.name,factor:e.factor,frozen:e.frozen,keyColumn:e.keyColumn,schema:e.schema,tags:e.tags,isComputeEnabled:e.isComputeEnabled}});var Ex=e=>({path:`/v1/tables/${encodeURIComponent(e.sourceTableId)}/duplicate`,headers:{},query:{},params:{sourceTableId:e.sourceTableId},body:{tableName:e.tableName,schemaOnly:e.schemaOnly,factor:e.factor}});var Wx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/export`,headers:{},query:{format:e.format,compress:e.compress},params:{table:e.table},body:{}});var Hx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/jobs`,headers:{},query:{},params:{table:e.table},body:{}});var Dx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/import`,headers:{},query:{},params:{table:e.table},body:{fileId:e.fileId}});var Mx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{name:e.name,frozen:e.frozen,keyColumn:e.keyColumn,schema:e.schema,tags:e.tags,isComputeEnabled:e.isComputeEnabled,factor:e.factor}});var Vx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/column`,headers:{},query:{},params:{table:e.table},body:{name:e.name,newName:e.newName}});var Kx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{}});var zx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/row`,headers:{},query:{id:e.id},params:{table:e.table},body:{}});var jx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows/find`,headers:{},query:{},params:{table:e.table},body:{limit:e.limit,offset:e.offset,filter:e.filter,group:e.group,search:e.search,select:e.select,orderBy:e.orderBy,orderDirection:e.orderDirection}});var Zx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows`,headers:{},query:{},params:{table:e.table},body:{rows:e.rows,waitComputed:e.waitComputed}});var ek=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows/delete`,headers:{},query:{},params:{table:e.table},body:{ids:e.ids,filter:e.filter,deleteAllRows:e.deleteAllRows}});var rk=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows`,headers:{},query:{},params:{table:e.table},body:{rows:e.rows,waitComputed:e.waitComputed}});var nk=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows/upsert`,headers:{},query:{},params:{table:e.table},body:{rows:e.rows,keyColumn:e.keyColumn,waitComputed:e.waitComputed}});var Gt=class{constructor(t,s={}){this.httpClient=t;this.props=s}createConversation=async t=>{let{path:s,headers:n,query:a,body:o}=aR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getConversation=async t=>{let{path:s,headers:n,query:a,body:o}=iR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listConversations=async t=>{let{path:s,headers:n,query:a,body:o}=uR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateConversation=async t=>{let{path:s,headers:n,query:a,body:o}=dR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateConversation=async t=>{let{path:s,headers:n,query:a,body:o}=gR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteConversation=async t=>{let{path:s,headers:n,query:a,body:o}=mR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listParticipants=async t=>{let{path:s,headers:n,query:a,body:o}=qR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};addParticipant=async t=>{let{path:s,headers:n,query:a,body:o}=bR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getParticipant=async t=>{let{path:s,headers:n,query:a,body:o}=IR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};removeParticipant=async t=>{let{path:s,headers:n,query:a,body:o}=kR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createEvent=async t=>{let{path:s,headers:n,query:a,body:o}=vR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getEvent=async t=>{let{path:s,headers:n,query:a,body:o}=CR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listEvents=async t=>{let{path:s,headers:n,query:a,body:o}=TR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};cancelScheduledEvent=async t=>{let{path:s,headers:n,query:a,body:o}=UR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createMessage=async t=>{let{path:s,headers:n,query:a,body:o}=SR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateMessage=async t=>{let{path:s,headers:n,query:a,body:o}=LR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getMessage=async t=>{let{path:s,headers:n,query:a,body:o}=_R(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateMessage=async t=>{let{path:s,headers:n,query:a,body:o}=QR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listMessages=async t=>{let{path:s,headers:n,query:a,body:o}=FR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteMessage=async t=>{let{path:s,headers:n,query:a,body:o}=OR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};initializeIncomingMessage=async t=>{let{path:s,headers:n,query:a,body:o}=NR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};importMessages=async t=>{let{path:s,headers:n,query:a,body:o}=$R(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createUser=async t=>{let{path:s,headers:n,query:a,body:o}=JR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getUser=async t=>{let{path:s,headers:n,query:a,body:o}=YR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsers=async t=>{let{path:s,headers:n,query:a,body:o}=XR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateUser=async t=>{let{path:s,headers:n,query:a,body:o}=tq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateUser=async t=>{let{path:s,headers:n,query:a,body:o}=sq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteUser=async t=>{let{path:s,headers:n,query:a,body:o}=aq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setStateExpiry=async t=>{let{path:s,headers:n,query:a,body:o}=iq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getState=async t=>{let{path:s,headers:n,query:a,body:o}=uq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setState=async t=>{let{path:s,headers:n,query:a,body:o}=dq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrSetState=async t=>{let{path:s,headers:n,query:a,body:o}=gq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};patchState=async t=>{let{path:s,headers:n,query:a,body:o}=mq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"patch",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};callAction=async t=>{let{path:s,headers:n,query:a,body:o}=qq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};unlinkIntegrationIdentifier=async t=>{let{path:s,headers:n,query:a,body:o}=bq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationIdentifierAvailability=async t=>{let{path:s,headers:n,query:a,body:o}=Iq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};configureIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=kq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=vq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=Cq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=Tq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=Uq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkflows=async t=>{let{path:s,headers:n,query:a,body:o}=Sq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=Lq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listTagValues=async t=>{let{path:s,headers:n,query:a,body:o}=_q(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};trackAnalytics=async t=>{let{path:s,headers:n,query:a,body:o}=Qq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};captureObservation=async t=>{let{path:s,headers:n,query:a,body:o}=Fq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};runVrl=async t=>{let{path:s,headers:n,query:a,body:o}=Oq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAccount=async t=>{let{path:s,headers:n,query:a,body:o}=Nq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateAccount=async t=>{let{path:s,headers:n,query:a,body:o}=$q(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteAccount=async t=>{let{path:s,headers:n,query:a,body:o}=Jq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPersonalAccessTokens=async t=>{let{path:s,headers:n,query:a,body:o}=Yq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createPersonalAccessToken=async t=>{let{path:s,headers:n,query:a,body:o}=Xq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deletePersonalAccessToken=async t=>{let{path:s,headers:n,query:a,body:o}=th(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setAccountPreference=async t=>{let{path:s,headers:n,query:a,body:o}=sh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAccountPreference=async t=>{let{path:s,headers:n,query:a,body:o}=ah(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicIntegrations=async t=>{let{path:s,headers:n,query:a,body:o}=ih(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicIntegrationById=async t=>{let{path:s,headers:n,query:a,body:o}=uh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=dh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicPlugins=async t=>{let{path:s,headers:n,query:a,body:o}=gh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicPluginById=async t=>{let{path:s,headers:n,query:a,body:o}=mh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getDereferencedPublicPluginById=async t=>{let{path:s,headers:n,query:a,body:o}=qh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=bh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicPluginCode=async t=>{let{path:s,headers:n,query:a,body:o}=Ih(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicInterfaces=async t=>{let{path:s,headers:n,query:a,body:o}=kh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicInterfaceById=async t=>{let{path:s,headers:n,query:a,body:o}=vh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicInterface=async t=>{let{path:s,headers:n,query:a,body:o}=Ch(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createBot=async t=>{let{path:s,headers:n,query:a,body:o}=Th(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateBot=async t=>{let{path:s,headers:n,query:a,body:o}=Uh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};rotateBotSigningSecrets=async t=>{let{path:s,headers:n,query:a,body:o}=Sh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};transferBot=async t=>{let{path:s,headers:n,query:a,body:o}=Lh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBots=async t=>{let{path:s,headers:n,query:a,body:o}=_h(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBot=async t=>{let{path:s,headers:n,query:a,body:o}=Qh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteBot=async t=>{let{path:s,headers:n,query:a,body:o}=Fh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotLogs=async t=>{let{path:s,headers:n,query:a,body:o}=Oh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotWebchat=async t=>{let{path:s,headers:n,query:a,body:o}=Nh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotAnalytics=async t=>{let{path:s,headers:n,query:a,body:o}=$h(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listActionRuns=async t=>{let{path:s,headers:n,query:a,body:o}=Jh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotIssue=async t=>{let{path:s,headers:n,query:a,body:o}=Yh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotIssues=async t=>{let{path:s,headers:n,query:a,body:o}=Xh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteBotIssue=async t=>{let{path:s,headers:n,query:a,body:o}=tb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotIssueEvents=async t=>{let{path:s,headers:n,query:a,body:o}=sb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotVersions=async t=>{let{path:s,headers:n,query:a,body:o}=ab(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotVersion=async t=>{let{path:s,headers:n,query:a,body:o}=ib(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotJson=async t=>{let{path:s,headers:n,query:a,body:o}=ub(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};publishFromBotJson=async t=>{let{path:s,headers:n,query:a,body:o}=db(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createBotVersion=async t=>{let{path:s,headers:n,query:a,body:o}=gb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deployBotVersion=async t=>{let{path:s,headers:n,query:a,body:o}=mb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createIntegrationShareableId=async t=>{let{path:s,headers:n,query:a,body:o}=qb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteIntegrationShareableId=async t=>{let{path:s,headers:n,query:a,body:o}=bb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationShareableId=async t=>{let{path:s,headers:n,query:a,body:o}=Ib(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};unlinkSandboxedConversations=async t=>{let{path:s,headers:n,query:a,body:o}=kb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotApiKeys=async t=>{let{path:s,headers:n,query:a,body:o}=vb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createBotApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=Cb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteBotApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=Tb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotAllowlist=async t=>{let{path:s,headers:n,query:a,body:o}=Ub(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateBotAllowlist=async t=>{let{path:s,headers:n,query:a,body:o}=Sb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};migrateWorkspaceToV4=async t=>{let{path:s,headers:n,query:a,body:o}=Lb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceInvoices=async t=>{let{path:s,headers:n,query:a,body:o}=_b(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getUpcomingInvoice=async t=>{let{path:s,headers:n,query:a,body:o}=Qb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};chargeWorkspaceUnpaidInvoices=async t=>{let{path:s,headers:n,query:a,body:o}=Fb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=Ob(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=Nb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=$b(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceUsages=async t=>{let{path:s,headers:n,query:a,body:o}=Jb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};breakDownWorkspaceUsageByBot=async t=>{let{path:s,headers:n,query:a,body:o}=Yb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAllWorkspaceQuotaCompletion=async t=>{let{path:s,headers:n,query:a,body:o}=Xb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspaceQuota=async t=>{let{path:s,headers:n,query:a,body:o}=tf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceQuotas=async t=>{let{path:s,headers:n,query:a,body:o}=sf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=af(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};checkHandleAvailability=async t=>{let{path:s,headers:n,query:a,body:o}=pf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaces=async t=>{let{path:s,headers:n,query:a,body:o}=cf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicWorkspaces=async t=>{let{path:s,headers:n,query:a,body:o}=lf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=yf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAuditRecords=async t=>{let{path:s,headers:n,query:a,body:o}=Rf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setWorkspacePreference=async t=>{let{path:s,headers:n,query:a,body:o}=hf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspacePreference=async t=>{let{path:s,headers:n,query:a,body:o}=ff(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceMembers=async t=>{let{path:s,headers:n,query:a,body:o}=xf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=Pf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=Af(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=Bf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=wf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listIntegrationApiKeys=async t=>{let{path:s,headers:n,query:a,body:o}=Gf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createIntegrationApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=Ef(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteIntegrationApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=Wf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=Hf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};validateIntegrationCreation=async t=>{let{path:s,headers:n,query:a,body:o}=Df(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=Mf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};rotateIntegrationSigningSecrets=async t=>{let{path:s,headers:n,query:a,body:o}=Vf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};validateIntegrationUpdate=async t=>{let{path:s,headers:n,query:a,body:o}=Kf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listIntegrations=async t=>{let{path:s,headers:n,query:a,body:o}=zf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=jf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationLogs=async t=>{let{path:s,headers:n,query:a,body:o}=Zf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationByName=async t=>{let{path:s,headers:n,query:a,body:o}=eI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=rI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};requestIntegrationVerification=async t=>{let{path:s,headers:n,query:a,body:o}=nI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createInterface=async t=>{let{path:s,headers:n,query:a,body:o}=oI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getInterface=async t=>{let{path:s,headers:n,query:a,body:o}=pI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getInterfaceByName=async t=>{let{path:s,headers:n,query:a,body:o}=cI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateInterface=async t=>{let{path:s,headers:n,query:a,body:o}=lI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteInterface=async t=>{let{path:s,headers:n,query:a,body:o}=yI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listInterfaces=async t=>{let{path:s,headers:n,query:a,body:o}=RI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=hI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=fI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getDereferencedPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=xI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPluginByName=async t=>{let{path:s,headers:n,query:a,body:o}=PI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updatePlugin=async t=>{let{path:s,headers:n,query:a,body:o}=AI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deletePlugin=async t=>{let{path:s,headers:n,query:a,body:o}=BI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPlugins=async t=>{let{path:s,headers:n,query:a,body:o}=wI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPluginCode=async t=>{let{path:s,headers:n,query:a,body:o}=GI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getUsage=async t=>{let{path:s,headers:n,query:a,body:o}=EI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getMultipleUsages=async t=>{let{path:s,headers:n,query:a,body:o}=WI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsageHistory=async t=>{let{path:s,headers:n,query:a,body:o}=HI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsageActivity=async t=>{let{path:s,headers:n,query:a,body:o}=DI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsageActivityDaily=async t=>{let{path:s,headers:n,query:a,body:o}=MI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};changeAISpendQuota=async t=>{let{path:s,headers:n,query:a,body:o}=VI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listActivities=async t=>{let{path:s,headers:n,query:a,body:o}=KI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};introspect=async t=>{let{path:s,headers:n,query:a,body:o}=zI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};upsertFile=async t=>{let{path:s,headers:n,query:a,body:o}=jI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteFile=async t=>{let{path:s,headers:n,query:a,body:o}=ZI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFiles=async t=>{let{path:s,headers:n,query:a,body:o}=ex(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getFile=async t=>{let{path:s,headers:n,query:a,body:o}=rx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateFileMetadata=async t=>{let{path:s,headers:n,query:a,body:o}=nx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};copyFile=async t=>{let{path:s,headers:n,query:a,body:o}=ox(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};searchFiles=async t=>{let{path:s,headers:n,query:a,body:o}=px(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFilePassages=async t=>{let{path:s,headers:n,query:a,body:o}=cx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setFilePassages=async t=>{let{path:s,headers:n,query:a,body:o}=lx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFileTags=async t=>{let{path:s,headers:n,query:a,body:o}=yx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFileTagValues=async t=>{let{path:s,headers:n,query:a,body:o}=Rx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createKnowledgeBase=async t=>{let{path:s,headers:n,query:a,body:o}=hx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteKnowledgeBase=async t=>{let{path:s,headers:n,query:a,body:o}=fx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateKnowledgeBase=async t=>{let{path:s,headers:n,query:a,body:o}=xx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listKnowledgeBases=async t=>{let{path:s,headers:n,query:a,body:o}=Px(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listTables=async t=>{let{path:s,headers:n,query:a,body:o}=Ax(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getTable=async t=>{let{path:s,headers:n,query:a,body:o}=Bx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateTable=async t=>{let{path:s,headers:n,query:a,body:o}=wx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createTable=async t=>{let{path:s,headers:n,query:a,body:o}=Gx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};duplicateTable=async t=>{let{path:s,headers:n,query:a,body:o}=Ex(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};exportTable=async t=>{let{path:s,headers:n,query:a,body:o}=Wx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getTableJobs=async t=>{let{path:s,headers:n,query:a,body:o}=Hx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};importTable=async t=>{let{path:s,headers:n,query:a,body:o}=Dx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateTable=async t=>{let{path:s,headers:n,query:a,body:o}=Mx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};renameTableColumn=async t=>{let{path:s,headers:n,query:a,body:o}=Vx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteTable=async t=>{let{path:s,headers:n,query:a,body:o}=Kx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getTableRow=async t=>{let{path:s,headers:n,query:a,body:o}=zx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};findTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=jx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=Zx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=ek(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=rk(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};upsertTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=nk(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})}};function d(e){let t=e?.response?.data;return t?we(t):we(e)}var ok=class extends Gt{config;constructor(t={}){let s=$.getClientConfig(t),n=W.createHttpClient(s);super(n,{toApiError:z.toApiError}),t.retry&&(n.retry=t.retry),this.config=s}get list(){return{conversations:t=>new R.AsyncCollection(({nextToken:s})=>this.listConversations({nextToken:s,...t}).then(n=>({...n,items:n.conversations}))),participants:t=>new R.AsyncCollection(({nextToken:s})=>this.listParticipants({nextToken:s,...t}).then(n=>({...n,items:n.participants}))),events:t=>new R.AsyncCollection(({nextToken:s})=>this.listEvents({nextToken:s,...t}).then(n=>({...n,items:n.events}))),messages:t=>new R.AsyncCollection(({nextToken:s})=>this.listMessages({nextToken:s,...t}).then(n=>({...n,items:n.messages}))),users:t=>new R.AsyncCollection(({nextToken:s})=>this.listUsers({nextToken:s,...t}).then(n=>({...n,items:n.users}))),publicIntegrations:t=>new R.AsyncCollection(({nextToken:s})=>this.listPublicIntegrations({nextToken:s,...t}).then(n=>({...n,items:n.integrations}))),bots:t=>new R.AsyncCollection(({nextToken:s})=>this.listBots({nextToken:s,...t}).then(n=>({...n,items:n.bots}))),botIssues:t=>new R.AsyncCollection(({nextToken:s})=>this.listBotIssues({nextToken:s,...t}).then(n=>({...n,items:n.issues}))),workspaces:t=>new R.AsyncCollection(({nextToken:s})=>this.listWorkspaces({nextToken:s,...t}).then(n=>({...n,items:n.workspaces}))),publicWorkspaces:t=>new R.AsyncCollection(({nextToken:s})=>this.listPublicWorkspaces({nextToken:s,...t}).then(n=>({...n,items:n.workspaces}))),workspaceMembers:t=>new R.AsyncCollection(({nextToken:s})=>this.listWorkspaceMembers({nextToken:s,...t}).then(n=>({...n,items:n.members}))),integrations:t=>new R.AsyncCollection(({nextToken:s})=>this.listIntegrations({nextToken:s,...t}).then(n=>({...n,items:n.integrations}))),interfaces:t=>new R.AsyncCollection(({nextToken:s})=>this.listInterfaces({nextToken:s,...t}).then(n=>({...n,items:n.interfaces}))),publicInterfaces:t=>new R.AsyncCollection(({nextToken:s})=>this.listPublicInterfaces({nextToken:s,...t}).then(n=>({...n,items:n.interfaces}))),plugins:t=>new R.AsyncCollection(({nextToken:s})=>this.listPlugins({nextToken:s,...t}).then(n=>({...n,items:n.plugins}))),publicPlugins:t=>new R.AsyncCollection(({nextToken:s})=>this.listPublicPlugins({nextToken:s,...t}).then(n=>({...n,items:n.plugins}))),activities:t=>new R.AsyncCollection(({nextToken:s})=>this.listActivities({nextToken:s,...t}).then(n=>({...n,items:n.activities}))),files:t=>new R.AsyncCollection(({nextToken:s})=>this.listFiles({nextToken:s,...t}).then(n=>({...n,items:n.files}))),filePassages:t=>new R.AsyncCollection(({nextToken:s})=>this.listFilePassages({nextToken:s,...t}).then(n=>({...n,items:n.passages}))),fileTags:t=>new R.AsyncCollection(({nextToken:s})=>this.listFileTags({nextToken:s,...t}).then(n=>({...n,items:n.tags}))),fileTagValues:t=>new R.AsyncCollection(({nextToken:s})=>this.listFileTagValues({nextToken:s,...t}).then(n=>({...n,items:n.values}))),knowledgeBases:t=>new R.AsyncCollection(({nextToken:s})=>this.listKnowledgeBases({nextToken:s,...t}).then(n=>({...n,items:n.knowledgeBases}))),usageActivity:t=>new R.AsyncCollection(({nextToken:s})=>this.listUsageActivity({nextToken:s,...t}).then(n=>({...n,items:n.data}))),usageActivityDaily:t=>new R.AsyncCollection(({nextToken:s})=>this.listUsageActivityDaily({nextToken:s,...t}).then(n=>({...n,items:n.data}))),workflows:t=>new R.AsyncCollection(({nextToken:s})=>this.listWorkflows({nextToken:s,...t}).then(n=>({...n,items:n.workflows})))}}uploadFile=async t=>await wt(this,t)};export{er as AlreadyExistsError,ar as BreakingChangesError,ok as Client,Ht as ForbiddenError,Wt as InternalError,Nt as InvalidDataFormatError,Kt as InvalidIdentifierError,Vt as InvalidJsonSchemaError,Dt as InvalidPayloadError,Zt as InvalidQueryError,nr as LimitExceededError,Mt as MethodNotFoundError,or as OperationTimeoutError,Qt as PayloadTooLargeError,rr as PaymentRequiredError,sr as QuotaExceededError,tr as RateLimitedError,zt as ReferenceConstraintError,Yt as ReferenceNotFoundError,$t as RelationConflictError,jt as ResourceGoneError,Jt as ResourceLockedConflictError,Ot as ResourceNotFoundError,Xt as RuntimeError,_t as UnauthorizedError,ye as UnknownError,Ft as UnsupportedMediaTypeError,ie as UploadFileError,Wg as admin,My as billing,we as errorFrom,Im as files,W as http,Fk as isApiError,Bu as runtime,sR as tables};
4
+ `+t.prev}function ft(e,t){var s=ps(e),n=[];if(s){n.length=e.length;for(var a=0;a<e.length;a++)n[a]=re(e,a)?t(e[a],e):""}var o=typeof ss=="function"?ss(e):[],i;if(Me){i={};for(var p=0;p<o.length;p++)i["$"+o[p]]=o[p]}for(var u in e)re(e,u)&&(s&&String(Number(u))===u&&u<e.length||Me&&i["$"+u]instanceof Symbol||(bi.call(/[^\w$]/,u)?n.push(t(u,e)+": "+t(e[u],e)):n.push(u+": "+t(e[u],e))));if(typeof ss=="function")for(var r=0;r<o.length;r++)fi.call(e,o[r])&&n.push("["+t(o[r])+"]: "+t(e[o[r]],e));return n}});var Ti=h((PB,Bi)=>{"use strict";var gs=Uo(),Oe=ai(),sA=Ci(),nA=gs("%TypeError%"),kt=gs("%WeakMap%",!0),Pt=gs("%Map%",!0),aA=Oe("WeakMap.prototype.get",!0),oA=Oe("WeakMap.prototype.set",!0),iA=Oe("WeakMap.prototype.has",!0),pA=Oe("Map.prototype.get",!0),uA=Oe("Map.prototype.set",!0),cA=Oe("Map.prototype.has",!0),ys=function(e,t){for(var s=e,n;(n=s.next)!==null;s=n)if(n.key===t)return s.next=n.next,n.next=e.next,e.next=n,n},dA=function(e,t){var s=ys(e,t);return s&&s.value},lA=function(e,t,s){var n=ys(e,t);n?n.value=s:e.next={key:t,next:e.next,value:s}},gA=function(e,t){return!!ys(e,t)};Bi.exports=function(){var t,s,n,a={assert:function(o){if(!a.has(o))throw new nA("Side channel does not contain "+sA(o))},get:function(o){if(kt&&o&&(typeof o=="object"||typeof o=="function")){if(t)return aA(t,o)}else if(Pt){if(s)return pA(s,o)}else if(n)return dA(n,o)},has:function(o){if(kt&&o&&(typeof o=="object"||typeof o=="function")){if(t)return iA(t,o)}else if(Pt){if(s)return cA(s,o)}else if(n)return gA(n,o);return!1},set:function(o,i){kt&&o&&(typeof o=="object"||typeof o=="function")?(t||(t=new kt),oA(t,o,i)):Pt?(s||(s=new Pt),uA(s,o,i)):(n||(n={key:{},next:null}),lA(n,o,i))}};return a}});var vt=h((vB,wi)=>{"use strict";var yA=String.prototype.replace,mA=/%20/g,ms={RFC1738:"RFC1738",RFC3986:"RFC3986"};wi.exports={default:ms.RFC3986,formatters:{RFC1738:function(e){return yA.call(e,mA,"+")},RFC3986:function(e){return String(e)}},RFC1738:ms.RFC1738,RFC3986:ms.RFC3986}});var qs=h((AB,Gi)=>{"use strict";var RA=vt(),Rs=Object.prototype.hasOwnProperty,Ie=Array.isArray,X=(function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e})(),qA=function(t){for(;t.length>1;){var s=t.pop(),n=s.obj[s.prop];if(Ie(n)){for(var a=[],o=0;o<n.length;++o)typeof n[o]<"u"&&a.push(n[o]);s.obj[s.prop]=a}}},Ui=function(t,s){for(var n=s&&s.plainObjects?Object.create(null):{},a=0;a<t.length;++a)typeof t[a]<"u"&&(n[a]=t[a]);return n},hA=function e(t,s,n){if(!s)return t;if(typeof s!="object"){if(Ie(t))t.push(s);else if(t&&typeof t=="object")(n&&(n.plainObjects||n.allowPrototypes)||!Rs.call(Object.prototype,s))&&(t[s]=!0);else return[t,s];return t}if(!t||typeof t!="object")return[t].concat(s);var a=t;return Ie(t)&&!Ie(s)&&(a=Ui(t,n)),Ie(t)&&Ie(s)?(s.forEach(function(o,i){if(Rs.call(t,i)){var p=t[i];p&&typeof p=="object"&&o&&typeof o=="object"?t[i]=e(p,o,n):t.push(o)}else t[i]=o}),t):Object.keys(s).reduce(function(o,i){var p=s[i];return Rs.call(o,i)?o[i]=e(o[i],p,n):o[i]=p,o},a)},bA=function(t,s){return Object.keys(s).reduce(function(n,a){return n[a]=s[a],n},t)},fA=function(e,t,s){var n=e.replace(/\+/g," ");if(s==="iso-8859-1")return n.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(n)}catch{return n}},IA=function(t,s,n,a,o){if(t.length===0)return t;var i=t;if(typeof t=="symbol"?i=Symbol.prototype.toString.call(t):typeof t!="string"&&(i=String(t)),n==="iso-8859-1")return escape(i).replace(/%u[0-9a-f]{4}/gi,function(y){return"%26%23"+parseInt(y.slice(2),16)+"%3B"});for(var p="",u=0;u<i.length;++u){var r=i.charCodeAt(u);if(r===45||r===46||r===95||r===126||r>=48&&r<=57||r>=65&&r<=90||r>=97&&r<=122||o===RA.RFC1738&&(r===40||r===41)){p+=i.charAt(u);continue}if(r<128){p=p+X[r];continue}if(r<2048){p=p+(X[192|r>>6]+X[128|r&63]);continue}if(r<55296||r>=57344){p=p+(X[224|r>>12]+X[128|r>>6&63]+X[128|r&63]);continue}u+=1,r=65536+((r&1023)<<10|i.charCodeAt(u)&1023),p+=X[240|r>>18]+X[128|r>>12&63]+X[128|r>>6&63]+X[128|r&63]}return p},xA=function(t){for(var s=[{obj:{o:t},prop:"o"}],n=[],a=0;a<s.length;++a)for(var o=s[a],i=o.obj[o.prop],p=Object.keys(i),u=0;u<p.length;++u){var r=p[u],y=i[r];typeof y=="object"&&y!==null&&n.indexOf(y)===-1&&(s.push({obj:i,prop:r}),n.push(y))}return qA(s),t},kA=function(t){return Object.prototype.toString.call(t)==="[object RegExp]"},PA=function(t){return!t||typeof t!="object"?!1:!!(t.constructor&&t.constructor.isBuffer&&t.constructor.isBuffer(t))},vA=function(t,s){return[].concat(t,s)},AA=function(t,s){if(Ie(t)){for(var n=[],a=0;a<t.length;a+=1)n.push(s(t[a]));return n}return s(t)};Gi.exports={arrayToObject:Ui,assign:bA,combine:vA,compact:xA,decode:fA,encode:IA,isBuffer:PA,isRegExp:kA,maybeMap:AA,merge:hA}});var Hi=h((CB,_i)=>{"use strict";var Li=Ti(),bs=qs(),nt=vt(),CA=Object.prototype.hasOwnProperty,Si={brackets:function(t){return t+"[]"},comma:"comma",indices:function(t,s){return t+"["+s+"]"},repeat:function(t){return t}},se=Array.isArray,BA=String.prototype.split,TA=Array.prototype.push,Wi=function(e,t){TA.apply(e,se(t)?t:[t])},wA=Date.prototype.toISOString,Ei=nt.default,F={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:bs.encode,encodeValuesOnly:!1,format:Ei,formatter:nt.formatters[Ei],indices:!1,serializeDate:function(t){return wA.call(t)},skipNulls:!1,strictNullHandling:!1},UA=function(t){return typeof t=="string"||typeof t=="number"||typeof t=="boolean"||typeof t=="symbol"||typeof t=="bigint"},hs={},GA=function e(t,s,n,a,o,i,p,u,r,y,x,m,k,P,q,L){for(var I=t,K=L,J=0,j=!1;(K=K.get(hs))!==void 0&&!j;){var ce=K.get(t);if(J+=1,typeof ce<"u"){if(ce===J)throw new RangeError("Cyclic object value");j=!0}typeof K.get(hs)>"u"&&(J=0)}if(typeof u=="function"?I=u(s,I):I instanceof Date?I=x(I):n==="comma"&&se(I)&&(I=bs.maybeMap(I,function(St){return St instanceof Date?x(St):St})),I===null){if(o)return p&&!P?p(s,F.encoder,q,"key",m):s;I=""}if(UA(I)||bs.isBuffer(I)){if(p){var Ne=P?s:p(s,F.encoder,q,"key",m);if(n==="comma"&&P){for(var de=BA.call(String(I),","),Ke="",ne=0;ne<de.length;++ne)Ke+=(ne===0?"":",")+k(p(de[ne],F.encoder,q,"value",m));return[k(Ne)+(a&&se(I)&&de.length===1?"[]":"")+"="+Ke]}return[k(Ne)+"="+k(p(I,F.encoder,q,"value",m))]}return[k(s)+"="+k(String(I))]}var Ce=[];if(typeof I>"u")return Ce;var le;if(n==="comma"&&se(I))le=[{value:I.length>0?I.join(",")||null:void 0}];else if(se(u))le=u;else{var Be=Object.keys(I);le=r?Be.sort(r):Be}for(var Y=a&&se(I)&&I.length===1?s+"[]":s,ae=0;ae<le.length;++ae){var ee=le[ae],$e=typeof ee=="object"&&typeof ee.value<"u"?ee.value:I[ee];if(!(i&&$e===null)){var dk=se(I)?typeof n=="function"?n(Y,ee):Y:Y+(y?"."+ee:"["+ee+"]");L.set(t,J);var ka=Li();ka.set(hs,L),Wi(Ce,e($e,dk,n,a,o,i,p,u,r,y,x,m,k,P,q,ka))}}return Ce},SA=function(t){if(!t)return F;if(t.encoder!==null&&typeof t.encoder<"u"&&typeof t.encoder!="function")throw new TypeError("Encoder has to be a function.");var s=t.charset||F.charset;if(typeof t.charset<"u"&&t.charset!=="utf-8"&&t.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var n=nt.default;if(typeof t.format<"u"){if(!CA.call(nt.formatters,t.format))throw new TypeError("Unknown format option provided.");n=t.format}var a=nt.formatters[n],o=F.filter;return(typeof t.filter=="function"||se(t.filter))&&(o=t.filter),{addQueryPrefix:typeof t.addQueryPrefix=="boolean"?t.addQueryPrefix:F.addQueryPrefix,allowDots:typeof t.allowDots>"u"?F.allowDots:!!t.allowDots,charset:s,charsetSentinel:typeof t.charsetSentinel=="boolean"?t.charsetSentinel:F.charsetSentinel,delimiter:typeof t.delimiter>"u"?F.delimiter:t.delimiter,encode:typeof t.encode=="boolean"?t.encode:F.encode,encoder:typeof t.encoder=="function"?t.encoder:F.encoder,encodeValuesOnly:typeof t.encodeValuesOnly=="boolean"?t.encodeValuesOnly:F.encodeValuesOnly,filter:o,format:n,formatter:a,serializeDate:typeof t.serializeDate=="function"?t.serializeDate:F.serializeDate,skipNulls:typeof t.skipNulls=="boolean"?t.skipNulls:F.skipNulls,sort:typeof t.sort=="function"?t.sort:null,strictNullHandling:typeof t.strictNullHandling=="boolean"?t.strictNullHandling:F.strictNullHandling}};_i.exports=function(e,t){var s=e,n=SA(t),a,o;typeof n.filter=="function"?(o=n.filter,s=o("",s)):se(n.filter)&&(o=n.filter,a=o);var i=[];if(typeof s!="object"||s===null)return"";var p;t&&t.arrayFormat in Si?p=t.arrayFormat:t&&"indices"in t?p=t.indices?"indices":"repeat":p="indices";var u=Si[p];if(t&&"commaRoundTrip"in t&&typeof t.commaRoundTrip!="boolean")throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var r=u==="comma"&&t&&t.commaRoundTrip;a||(a=Object.keys(s)),n.sort&&a.sort(n.sort);for(var y=Li(),x=0;x<a.length;++x){var m=a[x];n.skipNulls&&s[m]===null||Wi(i,GA(s[m],m,u,r,n.strictNullHandling,n.skipNulls,n.encode?n.encoder:null,n.filter,n.sort,n.allowDots,n.serializeDate,n.format,n.formatter,n.encodeValuesOnly,n.charset,y))}var k=i.join(n.delimiter),P=n.addQueryPrefix===!0?"?":"";return n.charsetSentinel&&(n.charset==="iso-8859-1"?P+="utf8=%26%2310003%3B&":P+="utf8=%E2%9C%93&"),k.length>0?P+k:""}});var Fi=h((BB,Di)=>{"use strict";var Ve=qs(),fs=Object.prototype.hasOwnProperty,EA=Array.isArray,Q={allowDots:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:Ve.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},LA=function(e){return e.replace(/&#(\d+);/g,function(t,s){return String.fromCharCode(parseInt(s,10))})},Qi=function(e,t){return e&&typeof e=="string"&&t.comma&&e.indexOf(",")>-1?e.split(","):e},WA="utf8=%26%2310003%3B",_A="utf8=%E2%9C%93",HA=function(t,s){var n={},a=s.ignoreQueryPrefix?t.replace(/^\?/,""):t,o=s.parameterLimit===1/0?void 0:s.parameterLimit,i=a.split(s.delimiter,o),p=-1,u,r=s.charset;if(s.charsetSentinel)for(u=0;u<i.length;++u)i[u].indexOf("utf8=")===0&&(i[u]===_A?r="utf-8":i[u]===WA&&(r="iso-8859-1"),p=u,u=i.length);for(u=0;u<i.length;++u)if(u!==p){var y=i[u],x=y.indexOf("]="),m=x===-1?y.indexOf("="):x+1,k,P;m===-1?(k=s.decoder(y,Q.decoder,r,"key"),P=s.strictNullHandling?null:""):(k=s.decoder(y.slice(0,m),Q.decoder,r,"key"),P=Ve.maybeMap(Qi(y.slice(m+1),s),function(q){return s.decoder(q,Q.decoder,r,"value")})),P&&s.interpretNumericEntities&&r==="iso-8859-1"&&(P=LA(P)),y.indexOf("[]=")>-1&&(P=EA(P)?[P]:P),fs.call(n,k)?n[k]=Ve.combine(n[k],P):n[k]=P}return n},QA=function(e,t,s,n){for(var a=n?t:Qi(t,s),o=e.length-1;o>=0;--o){var i,p=e[o];if(p==="[]"&&s.parseArrays)i=[].concat(a);else{i=s.plainObjects?Object.create(null):{};var u=p.charAt(0)==="["&&p.charAt(p.length-1)==="]"?p.slice(1,-1):p,r=parseInt(u,10);!s.parseArrays&&u===""?i={0:a}:!isNaN(r)&&p!==u&&String(r)===u&&r>=0&&s.parseArrays&&r<=s.arrayLimit?(i=[],i[r]=a):u!=="__proto__"&&(i[u]=a)}a=i}return a},DA=function(t,s,n,a){if(t){var o=n.allowDots?t.replace(/\.([^.[]+)/g,"[$1]"):t,i=/(\[[^[\]]*])/,p=/(\[[^[\]]*])/g,u=n.depth>0&&i.exec(o),r=u?o.slice(0,u.index):o,y=[];if(r){if(!n.plainObjects&&fs.call(Object.prototype,r)&&!n.allowPrototypes)return;y.push(r)}for(var x=0;n.depth>0&&(u=p.exec(o))!==null&&x<n.depth;){if(x+=1,!n.plainObjects&&fs.call(Object.prototype,u[1].slice(1,-1))&&!n.allowPrototypes)return;y.push(u[1])}return u&&y.push("["+o.slice(u.index)+"]"),QA(y,s,n,a)}},FA=function(t){if(!t)return Q;if(t.decoder!==null&&t.decoder!==void 0&&typeof t.decoder!="function")throw new TypeError("Decoder has to be a function.");if(typeof t.charset<"u"&&t.charset!=="utf-8"&&t.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var s=typeof t.charset>"u"?Q.charset:t.charset;return{allowDots:typeof t.allowDots>"u"?Q.allowDots:!!t.allowDots,allowPrototypes:typeof t.allowPrototypes=="boolean"?t.allowPrototypes:Q.allowPrototypes,allowSparse:typeof t.allowSparse=="boolean"?t.allowSparse:Q.allowSparse,arrayLimit:typeof t.arrayLimit=="number"?t.arrayLimit:Q.arrayLimit,charset:s,charsetSentinel:typeof t.charsetSentinel=="boolean"?t.charsetSentinel:Q.charsetSentinel,comma:typeof t.comma=="boolean"?t.comma:Q.comma,decoder:typeof t.decoder=="function"?t.decoder:Q.decoder,delimiter:typeof t.delimiter=="string"||Ve.isRegExp(t.delimiter)?t.delimiter:Q.delimiter,depth:typeof t.depth=="number"||t.depth===!1?+t.depth:Q.depth,ignoreQueryPrefix:t.ignoreQueryPrefix===!0,interpretNumericEntities:typeof t.interpretNumericEntities=="boolean"?t.interpretNumericEntities:Q.interpretNumericEntities,parameterLimit:typeof t.parameterLimit=="number"?t.parameterLimit:Q.parameterLimit,parseArrays:t.parseArrays!==!1,plainObjects:typeof t.plainObjects=="boolean"?t.plainObjects:Q.plainObjects,strictNullHandling:typeof t.strictNullHandling=="boolean"?t.strictNullHandling:Q.strictNullHandling}};Di.exports=function(e,t){var s=FA(t);if(e===""||e===null||typeof e>"u")return s.plainObjects?Object.create(null):{};for(var n=typeof e=="string"?HA(e,s):e,a=s.plainObjects?Object.create(null):{},o=Object.keys(n),i=0;i<o.length;++i){var p=o[i],u=DA(p,n[p],s,typeof e=="string");a=Ve.merge(a,u,s)}return s.allowSparse===!0?a:Ve.compact(a)}});var xe=h((TB,Mi)=>{"use strict";var MA=Hi(),OA=Fi(),VA=vt();Mi.exports={formats:VA,parse:OA,stringify:MA}});var W={};te(W,{HttpClient:()=>at,HttpError:()=>oe,createHttpClient:()=>Ik,isHttpError:()=>ge,isNetworkError:()=>fk,isNetworkOrIdempotentRequestError:()=>va});var hk=()=>typeof globalThis.crypto<"u"&&typeof globalThis.crypto.randomUUID=="function"?globalThis.crypto.randomUUID():Math.random().toString(36).substring(2,15),oe=class extends Error{constructor(s,n,a,o,i){super(s);this.config=n;this.code=a;this.response=o;this.name="HttpError",i!==void 0&&(this.cause=i)}isHttpError=!0},ge=e=>e instanceof oe||typeof e=="object"&&e!==null&&e.isHttpError===!0,bk=["get","head","options","put","delete"],fk=e=>ge(e)&&!e.response,va=e=>{if(!ge(e))return!1;if(!e.response)return!0;let t=e.config.method?.toLowerCase()??"";return bk.includes(t)&&e.response.status>=500&&e.response.status<=599},Ik=e=>new at({baseURL:e.apiUrl,headers:e.headers,withCredentials:e.withCredentials,timeout:e.timeout,debug:e.debug}),at=class{defaults;retry;constructor(t={}){this.defaults={headers:{},...t}}async request(t){let s=this.retry;if(!s?.retries)return this._requestOnce(t);for(let n=1;;n++)try{return await this._requestOnce(t)}catch(a){let o=t.signal?.aborted||this.defaults.signal?.aborted;if(!ge(a)||o||n>s.retries||!await(s.retryCondition??va)(a))throw a;let p=s.retryDelay?.(n,a)??0;p>0&&await new Promise(u=>setTimeout(u,p))}}get(t,s={}){return this.request({...s,method:"get",url:t})}delete(t,s={}){return this.request({...s,method:"delete",url:t})}post(t,s,n={}){return this.request({...n,method:"post",url:t,data:s})}put(t,s,n={}){return this.request({...n,method:"put",url:t,data:s})}async _requestOnce(t){let s=(t.method??"get").toUpperCase(),n=xk(t.baseURL??this.defaults.baseURL,t.url??""),a={...t,method:s,url:n},o=new Headers;Pa(o,this.defaults.headers),Pa(o,t.headers);let i;t.data!==void 0&&t.data!==null&&(kk(t.data)?i=t.data:(i=JSON.stringify(t.data),o.has("content-type")||o.set("content-type","application/json")));let p=t.timeout??this.defaults.timeout,u=[];t.signal&&u.push(t.signal),this.defaults.signal&&u.push(this.defaults.signal);let r=!1,y;if(p&&p>0&&Number.isFinite(p)){let q=new AbortController;y=setTimeout(()=>{r=!0,q.abort()},p),u.push(q.signal)}let x=this.defaults.debug??!1,m=x?hk():void 0,k=Date.now();x&&console.debug(Ck(a,o,m));let P=q=>{if(r)return new oe(`timeout of ${p}ms exceeded`,a,"ECONNABORTED",void 0,q);if(t.signal?.aborted||this.defaults.signal?.aborted)return new oe("canceled",a,"ERR_CANCELED",void 0,q);let L=q?.cause,I=q?.message??"Network Error";return new oe(I,a,L?.code??"ERR_NETWORK",void 0,q)};try{let q=await fetch(n,{method:s,headers:o,body:i,signal:vk(u),credentials:t.withCredentials??this.defaults.withCredentials?"include":void 0}),L={};q.headers.forEach((j,ce)=>{L[ce]=j});let I,K=t.responseType??"json";if(!q.ok||K==="json"||K==="text"){let j=await q.text();I=!q.ok||K==="json"?Pk(j):j}else K==="arraybuffer"?I=await q.arrayBuffer():I=q.body?Ak(q.body):void 0;let J={data:I,status:q.status,statusText:q.statusText,headers:L,config:a};if(x&&console.debug(Bk(J,m,k)),!q.ok)throw new oe(`Request failed with status code ${q.status}`,a,void 0,J);return J}catch(q){let L=ge(q)?q:P(q);throw x&&!L.response&&console.debug(Tk(L,m,k)),L}finally{y!==void 0&&clearTimeout(y)}}},xk=(e,t)=>!e||/^https?:\/\//i.test(t)?t:t?`${e.replace(/\/+$/,"")}/${t.replace(/^\/+/,"")}`:e,Pa=(e,t)=>{for(let[s,n]of Object.entries(t??{})){if(n===void 0){e.delete(s);continue}if(Array.isArray(n)){e.delete(s);for(let a of n)e.append(s,a)}else e.set(s,n)}},kk=e=>typeof e=="string"||e instanceof Uint8Array||e instanceof ArrayBuffer||typeof Blob<"u"&&e instanceof Blob||typeof FormData<"u"&&e instanceof FormData||typeof URLSearchParams<"u"&&e instanceof URLSearchParams,Pk=e=>{if(e)try{return JSON.parse(e)}catch{return e}},vk=e=>{if(e.length===0)return;if(e.length===1)return e[0];if(typeof AbortSignal.any=="function")return AbortSignal.any(e);let t=new AbortController;for(let s of e){if(s.aborted){t.abort(s.reason);break}s.addEventListener("abort",()=>t.abort(s.reason),{once:!0})}return t.signal};async function*Ak(e){let t=e.getReader();try{for(;;){let{done:s,value:n}=await t.read();if(s)break;n&&(yield n)}}finally{t.releaseLock()}}var Ck=(e,t,s)=>{let n={};return t.forEach((a,o)=>{n[o]=a}),"REQUEST: "+JSON.stringify({method:e.method?.toUpperCase(),url:e.url,timestamp:new Date().toISOString(),requestId:s,headers:n,body:e.data})+`
5
+ `},Bk=(e,t,s)=>"RESPONSE: "+JSON.stringify({method:e.config.method?.toUpperCase(),status:e.status,url:e.config.url,timestamp:new Date().toISOString(),requestId:t,duration:`${Date.now()-s}ms`,headers:e.headers,body:e.data})+`
6
+ `,Tk=(e,t,s)=>"ERROR: "+JSON.stringify({status:e.code,url:e.config.url,timestamp:new Date().toISOString(),requestId:t??"N/A",duration:`${Date.now()-s}ms`});var wu={};te(wu,{Client:()=>Is});var $={};te($,{getClientConfig:()=>Qk});import{isBrowser as Aa,isNode as wk}from"browser-or-node";var Uk="https://api.botpress.cloud",Gk=6e4,Sk=!1,Ek="BP_API_URL",Lk="BP_BOT_ID",Wk="BP_INTEGRATION_ID",_k="BP_WORKSPACE_ID",Hk="BP_TOKEN";function Qk(e){let t=Dk(e),s={};t.workspaceId&&(s["x-workspace-id"]=t.workspaceId),t.botId&&(s["x-bot-id"]=t.botId),t.integrationId&&(s["x-integration-id"]=t.integrationId),t.integrationAlias&&(s["x-integration-alias"]=t.integrationAlias),t.token&&(s.Authorization=`Bearer ${t.token}`),s={...s,...t.headers};let n=t.apiUrl??Uk,a=t.timeout??Gk,o=t.debug??Sk;return{apiUrl:n,timeout:a,withCredentials:Aa,headers:s,debug:o}}function Dk(e){return Aa?e:wk?Fk(e):e}function Fk(e){let t={...e,apiUrl:e.apiUrl??process.env[Ek],botId:e.botId??process.env[Lk],integrationId:e.integrationId??process.env[Wk],integrationAlias:e.integrationAlias,workspaceId:e.workspaceId??process.env[_k]},s=t.token??process.env[Hk];return s&&(t.token=s),t}var R={};te(R,{AsyncCollection:()=>Lt});var Lt=class{constructor(t){this._list=t}async*[Symbol.asyncIterator](){let t;do{let{items:s,meta:n}=await this._list({nextToken:t});t=n.nextToken;for(let a of s)yield a}while(t)}async collect(t={}){let s=t.limit??Number.POSITIVE_INFINITY,n=[],a=0;for await(let o of this)if(n.push(o),a++,a>=s)break;return n}};var z={};te(z,{toApiError:()=>zk});var Mk={getRandomValues:e=>new Uint8Array(e.map(()=>Math.floor(Math.random()*256)))},Ok=typeof globalThis.crypto<"u"&&typeof globalThis.crypto.getRandomValues=="function"?globalThis.crypto:Mk,B=class e extends Error{constructor(s,n,a,o,i,p,u){super(o);this.code=s;this.description=n;this.type=a;this.message=o;this.error=i;this.id=p;this.metadata=u;this.id||(this.id=e.generateId())}isApiError=!0;format(){return`[${this.type}] ${this.message} (Error ID: ${this.id})`}toJSON(){return{id:this.id,code:this.code,type:this.type,message:this.message,metadata:this.metadata}}static generateId(){let s=this.getPrefix(),n=new Date().toISOString().replace(/[\-:TZ]/g,"").split(".")[0],a=4,o=Array.from(Ok.getRandomValues(new Uint8Array(a))).map(i=>i.toString(16).padStart(2,"0")).join("").toUpperCase();return`${s}_${n}x${o}`}static getPrefix(){return typeof window<"u"&&typeof window.document<"u"?"err_bwsr":"err"}},Vk=e=>typeof e=="object"&&!Array.isArray(e)&&e!==null,Nk=e=>e instanceof B||Vk(e)&&e.isApiError===!0,ye=class extends B{constructor(t,s,n,a){super(500,"An unknown error occurred","Unknown",t,s,n,a)}},Wt=class extends B{constructor(t,s,n,a){super(500,"An internal error occurred","Internal",t,s,n,a)}},_t=class extends B{constructor(t,s,n,a){super(401,"The request requires to be authenticated.","Unauthorized",t,s,n,a)}},Ht=class extends B{constructor(t,s,n,a){super(403,"The requested action can't be peform by this resource.","Forbidden",t,s,n,a)}},Qt=class extends B{constructor(t,s,n,a){super(413,"The request payload is too large.","PayloadTooLarge",t,s,n,a)}},Dt=class extends B{constructor(t,s,n,a){super(400,"The request payload is invalid.","InvalidPayload",t,s,n,a)}},Ft=class extends B{constructor(t,s,n,a){super(415,"The request is invalid because the content-type is not supported.","UnsupportedMediaType",t,s,n,a)}},Mt=class extends B{constructor(t,s,n,a){super(405,"The requested method does not exist.","MethodNotFound",t,s,n,a)}},Ot=class extends B{constructor(t,s,n,a){super(404,"The requested resource does not exist.","ResourceNotFound",t,s,n,a)}},Vt=class extends B{constructor(t,s,n,a){super(400,"The provided JSON schema is invalid.","InvalidJsonSchema",t,s,n,a)}},Nt=class extends B{constructor(t,s,n,a){super(400,"The provided data doesn't respect the provided JSON schema.","InvalidDataFormat",t,s,n,a)}},Kt=class extends B{constructor(t,s,n,a){super(400,"The provided identifier is not valid. An identifier must start with a lowercase letter, be between 2 and 100 characters long and use only alphanumeric characters.","InvalidIdentifier",t,s,n,a)}},$t=class extends B{constructor(t,s,n,a){super(409,"The resource is related with a different resource that the one referenced in the request. This is usually caused when providing two resource identifiers that aren't linked together.","RelationConflict",t,s,n,a)}},zt=class extends B{constructor(t,s,n,a){super(409,"The resource cannot be deleted because it's referenced by another resource","ReferenceConstraint",t,s,n,a)}},Jt=class extends B{constructor(t,s,n,a){super(409,"The resource is current locked and cannot be operated on until the lock is released.","ResourceLockedConflict",t,s,n,a)}},jt=class extends B{constructor(t,s,n,a){super(410,"The requested resource is no longer available.","ResourceGone",t,s,n,a)}},Yt=class extends B{constructor(t,s,n,a){super(400,"The provided resource reference is missing. This is usually caused when providing an invalid id inside the payload of a request.","ReferenceNotFound",t,s,n,a)}},Zt=class extends B{constructor(t,s,n,a){super(400,"The provided query is invalid. This is usually caused when providing an invalid parameter for querying a resource.","InvalidQuery",t,s,n,a)}},Xt=class extends B{constructor(t,s,n,a){super(400,"An error happened during the execution of a runtime (bot or integration).","Runtime",t,s,n,a)}},er=class extends B{constructor(t,s,n,a){super(409,"The record attempted to be created already exists.","AlreadyExists",t,s,n,a)}},tr=class extends B{constructor(t,s,n,a){super(429,"The request has been rate limited.","RateLimited",t,s,n,a)}},rr=class extends B{constructor(t,s,n,a){super(402,"A payment is required to perform this request.","PaymentRequired",t,s,n,a)}},sr=class extends B{constructor(t,s,n,a){super(403,"The request exceeds the allowed quota. Quotas are a soft limit that can be increased.","QuotaExceeded",t,s,n,a)}},nr=class extends B{constructor(t,s,n,a){super(413,"The request exceeds the allowed limit. Limits are a hard limit that cannot be increased.","LimitExceeded",t,s,n,a)}},ar=class extends B{constructor(t,s,n,a){super(400,"Request payload contains breaking changes which is not allowed for this resource without a version increment.","BreakingChanges",t,s,n,a)}},or=class extends B{constructor(t,s,n,a){super(504,"The operation timed out.","OperationTimeout",t,s,n,a)}},Kk={Unknown:ye,Internal:Wt,Unauthorized:_t,Forbidden:Ht,PayloadTooLarge:Qt,InvalidPayload:Dt,UnsupportedMediaType:Ft,MethodNotFound:Mt,ResourceNotFound:Ot,InvalidJsonSchema:Vt,InvalidDataFormat:Nt,InvalidIdentifier:Kt,RelationConflict:$t,ReferenceConstraint:zt,ResourceLockedConflict:Jt,ResourceGone:jt,ReferenceNotFound:Yt,InvalidQuery:Zt,Runtime:Xt,AlreadyExists:er,RateLimited:tr,PaymentRequired:rr,QuotaExceeded:sr,LimitExceeded:nr,BreakingChanges:ar,OperationTimeout:or},we=e=>Nk(e)?e:e instanceof Error?new ye(e.message,e):typeof e=="string"?new ye(e):$k(e);function $k(e){if(typeof e=="object"&&"code"in e&&"type"in e&&"id"in e&&"message"in e&&typeof e.type=="string"&&typeof e.message=="string"){let t=Kk[e.type];return t?new t(e.message,void 0,e.id||"UNKNOWN",e.metadata):new ye(`An unclassified API error occurred: ${e.message} (Type: ${e.type}, Code: ${e.code})`)}return new ye("An invalid error occurred: "+JSON.stringify(e))}var ie=class extends Error{constructor(s,n,a){super(s);this.innerError=n;this.file=a;this.name="FileUploadError"}};var zk=e=>ge(e)&&e.response?.data?we(e.response.data):we(e);var Jk={getRandomValues:e=>new Uint8Array(e.map(()=>Math.floor(Math.random()*256)))},jk=typeof globalThis.crypto<"u"&&typeof globalThis.crypto.getRandomValues=="function"?globalThis.crypto:Jk,T=class e extends Error{constructor(s,n,a,o,i,p,u){super(o);this.code=s;this.description=n;this.type=a;this.message=o;this.error=i;this.id=p;this.metadata=u;this.id||(this.id=e.generateId())}isApiError=!0;format(){return`[${this.type}] ${this.message} (Error ID: ${this.id})`}toJSON(){return{id:this.id,code:this.code,type:this.type,message:this.message,metadata:this.metadata}}static generateId(){let s=this.getPrefix(),n=new Date().toISOString().replace(/[\-:TZ]/g,"").split(".")[0],a=4,o=Array.from(jk.getRandomValues(new Uint8Array(a))).map(i=>i.toString(16).padStart(2,"0")).join("").toUpperCase();return`${s}_${n}x${o}`}static getPrefix(){return typeof window<"u"&&typeof window.document<"u"?"err_bwsr":"err"}},Yk=e=>typeof e=="object"&&!Array.isArray(e)&&e!==null,Zk=e=>e instanceof T||Yk(e)&&e.isApiError===!0,Re=class extends T{constructor(t,s,n,a){super(500,"An unknown error occurred","Unknown",t,s,n,a)}},ir=class extends T{constructor(t,s,n,a){super(500,"An internal error occurred","Internal",t,s,n,a)}},pr=class extends T{constructor(t,s,n,a){super(401,"The request requires to be authenticated.","Unauthorized",t,s,n,a)}},ur=class extends T{constructor(t,s,n,a){super(403,"The requested action can't be peform by this resource.","Forbidden",t,s,n,a)}},cr=class extends T{constructor(t,s,n,a){super(413,"The request payload is too large.","PayloadTooLarge",t,s,n,a)}},dr=class extends T{constructor(t,s,n,a){super(400,"The request payload is invalid.","InvalidPayload",t,s,n,a)}},lr=class extends T{constructor(t,s,n,a){super(415,"The request is invalid because the content-type is not supported.","UnsupportedMediaType",t,s,n,a)}},gr=class extends T{constructor(t,s,n,a){super(405,"The requested method does not exist.","MethodNotFound",t,s,n,a)}},yr=class extends T{constructor(t,s,n,a){super(404,"The requested resource does not exist.","ResourceNotFound",t,s,n,a)}},mr=class extends T{constructor(t,s,n,a){super(400,"The provided JSON schema is invalid.","InvalidJsonSchema",t,s,n,a)}},Rr=class extends T{constructor(t,s,n,a){super(400,"The provided data doesn't respect the provided JSON schema.","InvalidDataFormat",t,s,n,a)}},qr=class extends T{constructor(t,s,n,a){super(400,"The provided identifier is not valid. An identifier must start with a lowercase letter, be between 2 and 100 characters long and use only alphanumeric characters.","InvalidIdentifier",t,s,n,a)}},hr=class extends T{constructor(t,s,n,a){super(409,"The resource is related with a different resource that the one referenced in the request. This is usually caused when providing two resource identifiers that aren't linked together.","RelationConflict",t,s,n,a)}},br=class extends T{constructor(t,s,n,a){super(409,"The resource cannot be deleted because it's referenced by another resource","ReferenceConstraint",t,s,n,a)}},fr=class extends T{constructor(t,s,n,a){super(409,"The resource is current locked and cannot be operated on until the lock is released.","ResourceLockedConflict",t,s,n,a)}},Ir=class extends T{constructor(t,s,n,a){super(410,"The requested resource is no longer available.","ResourceGone",t,s,n,a)}},xr=class extends T{constructor(t,s,n,a){super(400,"The provided resource reference is missing. This is usually caused when providing an invalid id inside the payload of a request.","ReferenceNotFound",t,s,n,a)}},kr=class extends T{constructor(t,s,n,a){super(400,"The provided query is invalid. This is usually caused when providing an invalid parameter for querying a resource.","InvalidQuery",t,s,n,a)}},Pr=class extends T{constructor(t,s,n,a){super(400,"An error happened during the execution of a runtime (bot or integration).","Runtime",t,s,n,a)}},vr=class extends T{constructor(t,s,n,a){super(409,"The record attempted to be created already exists.","AlreadyExists",t,s,n,a)}},Ar=class extends T{constructor(t,s,n,a){super(429,"The request has been rate limited.","RateLimited",t,s,n,a)}},Cr=class extends T{constructor(t,s,n,a){super(402,"A payment is required to perform this request.","PaymentRequired",t,s,n,a)}},Br=class extends T{constructor(t,s,n,a){super(403,"The request exceeds the allowed quota. Quotas are a soft limit that can be increased.","QuotaExceeded",t,s,n,a)}},Tr=class extends T{constructor(t,s,n,a){super(413,"The request exceeds the allowed limit. Limits are a hard limit that cannot be increased.","LimitExceeded",t,s,n,a)}},wr=class extends T{constructor(t,s,n,a){super(400,"Request payload contains breaking changes which is not allowed for this resource without a version increment.","BreakingChanges",t,s,n,a)}},Ur=class extends T{constructor(t,s,n,a){super(504,"The operation timed out.","OperationTimeout",t,s,n,a)}},Xk={Unknown:Re,Internal:ir,Unauthorized:pr,Forbidden:ur,PayloadTooLarge:cr,InvalidPayload:dr,UnsupportedMediaType:lr,MethodNotFound:gr,ResourceNotFound:yr,InvalidJsonSchema:mr,InvalidDataFormat:Rr,InvalidIdentifier:qr,RelationConflict:hr,ReferenceConstraint:br,ResourceLockedConflict:fr,ResourceGone:Ir,ReferenceNotFound:xr,InvalidQuery:kr,Runtime:Pr,AlreadyExists:vr,RateLimited:Ar,PaymentRequired:Cr,QuotaExceeded:Br,LimitExceeded:Tr,BreakingChanges:wr,OperationTimeout:Ur},Gr=e=>Zk(e)?e:e instanceof Error?new Re(e.message,e):typeof e=="string"?new Re(e):eP(e);function eP(e){if(typeof e=="object"&&"code"in e&&"type"in e&&"id"in e&&"message"in e&&typeof e.type=="string"&&typeof e.message=="string"){let t=Xk[e.type];return t?new t(e.message,void 0,e.id||"UNKNOWN",e.metadata):new Re(`An unclassified API error occurred: ${e.message} (Type: ${e.type}, Code: ${e.code})`)}return new Re("An invalid error occurred: "+JSON.stringify(e))}var Oi=Te(xe()),NA=e=>e[1]!==void 0,b=e=>{let{method:t,path:s,query:n,headers:a,body:o}=e,i=Object.entries(a).filter(NA),p=Object.fromEntries(i),u=Oi.default.stringify(n,{encode:!0,arrayFormat:"repeat",allowDots:!0}),r=u?[s,u].join("?"):s,y=["put","post","delete","patch"].includes(t.toLowerCase())?o:void 0;return{method:t,url:r,headers:p,data:y}};var Vi=e=>({path:"/v1/chat/conversations",headers:{},query:{},params:{},body:{channel:e.channel,tags:e.tags,integrationName:e.integrationName,properties:e.properties}});var Ki=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var zi=e=>({path:"/v1/chat/conversations",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,sortField:e.sortField,sortDirection:e.sortDirection,tags:e.tags,participantIds:e.participantIds,integrationName:e.integrationName,channel:e.channel,afterDate:e.afterDate,beforeDate:e.beforeDate,minMessageCount:e.minMessageCount,maxMessageCount:e.maxMessageCount},params:{},body:{}});var ji=e=>({path:"/v1/chat/conversations/get-or-create",headers:{},query:{},params:{},body:{channel:e.channel,tags:e.tags,integrationName:e.integrationName,properties:e.properties,discriminateByTags:e.discriminateByTags}});var Zi=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{currentTaskId:e.currentTaskId,tags:e.tags,properties:e.properties}});var ep=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var rp=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var np=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants`,headers:{},query:{},params:{id:e.id},body:{userId:e.userId}});var op=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants/${encodeURIComponent(e.userId)}`,headers:{},query:{},params:{id:e.id,userId:e.userId},body:{}});var pp=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants/${encodeURIComponent(e.userId)}`,headers:{},query:{},params:{id:e.id,userId:e.userId},body:{}});var cp=e=>({path:"/v1/chat/events",headers:{},query:{},params:{},body:{type:e.type,payload:e.payload,schedule:e.schedule,conversationId:e.conversationId,userId:e.userId,workflowId:e.workflowId,messageId:e.messageId}});var lp=e=>({path:`/v1/chat/events/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var yp=e=>({path:"/v1/chat/events",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,type:e.type,conversationId:e.conversationId,userId:e.userId,messageId:e.messageId,workflowId:e.workflowId,status:e.status},params:{},body:{}});var Rp=e=>({path:`/v1/chat/events/scheduled/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var hp=e=>({path:"/v1/chat/messages",headers:{},query:{},params:{},body:{payload:e.payload,userId:e.userId,conversationId:e.conversationId,type:e.type,tags:e.tags,schedule:e.schedule,origin:e.origin}});var fp=e=>({path:"/v1/chat/messages/get-or-create",headers:{},query:{},params:{},body:{payload:e.payload,userId:e.userId,conversationId:e.conversationId,type:e.type,tags:e.tags,schedule:e.schedule,origin:e.origin,discriminateByTags:e.discriminateByTags}});var xp=e=>({path:`/v1/chat/messages/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Pp=e=>({path:`/v1/chat/messages/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{tags:e.tags,payload:e.payload}});var Ap=e=>({path:"/v1/chat/messages",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,conversationId:e.conversationId,tags:e.tags,afterDate:e.afterDate,beforeDate:e.beforeDate},params:{},body:{}});var Bp=e=>({path:`/v1/chat/messages/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var wp=e=>({path:"/v1/chat/initialize-incoming-message",headers:{},query:{},params:{},body:{userId:e.userId,user:e.user,conversationId:e.conversationId,conversation:e.conversation,message:e.message}});var Gp=e=>({path:"/v1/chat/messages/import-messages",headers:{},query:{},params:{},body:{messages:e.messages}});var Ep=e=>({path:"/v1/chat/users",headers:{},query:{},params:{},body:{tags:e.tags,integrationName:e.integrationName,name:e.name,pictureUrl:e.pictureUrl,properties:e.properties,attributes:e.attributes}});var Wp=e=>({path:`/v1/chat/users/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Hp=e=>({path:"/v1/chat/users",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,conversationId:e.conversationId,tags:e.tags,afterDate:e.afterDate,beforeDate:e.beforeDate,rangeField:e.rangeField,sortField:e.sortField,sortDirection:e.sortDirection},params:{},body:{}});var Dp=e=>({path:"/v1/chat/users/get-or-create",headers:{},query:{},params:{},body:{tags:e.tags,integrationName:e.integrationName,name:e.name,pictureUrl:e.pictureUrl,properties:e.properties,attributes:e.attributes,discriminateByTags:e.discriminateByTags}});var Mp=e=>({path:`/v1/chat/users/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{tags:e.tags,name:e.name,pictureUrl:e.pictureUrl,attributes:e.attributes,properties:e.properties}});var Vp=e=>({path:`/v1/chat/users/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Kp=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}/expiry`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{expiry:e.expiry}});var zp=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{}});var jp=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{payload:e.payload,expiry:e.expiry}});var Zp=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}/get-or-set`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{payload:e.payload,expiry:e.expiry}});var eu=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{payload:e.payload,expiry:e.expiry}});var ru=e=>({path:"/v1/chat/actions",headers:{},query:{},params:{},body:{type:e.type,input:e.input}});var nu=e=>({path:"/v1/chat/integration/identifiers",headers:{},query:{value:e.value},params:{},body:{}});var ou=e=>({path:"/v1/chat/integration/identifiers/availability",headers:{},query:{value:e.value},params:{},body:{}});var pu=e=>({path:"/v1/chat/integration-instance/identifiers",headers:{},query:{},params:{},body:{}});var cu=e=>({path:"/v1/chat/integrations/configure",headers:{},query:{},params:{},body:{identifier:e.identifier,identifiers:e.identifiers,scheduleRegisterCall:e.scheduleRegisterCall,sandboxIdentifiers:e.sandboxIdentifiers}});var lu=e=>({path:"/v1/chat/workflows",headers:{},query:{},params:{},body:{name:e.name,input:e.input,parentWorkflowId:e.parentWorkflowId,conversationId:e.conversationId,userId:e.userId,timeoutAt:e.timeoutAt,tags:e.tags,status:e.status,eventId:e.eventId}});var yu=e=>({path:`/v1/chat/workflows/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Ru=e=>({path:`/v1/chat/workflows/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{output:e.output,timeoutAt:e.timeoutAt,status:e.status,failureReason:e.failureReason,tags:e.tags,userId:e.userId,eventId:e.eventId}});var hu=e=>({path:`/v1/chat/workflows/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var fu=e=>({path:"/v1/chat/workflows",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,tags:e.tags,conversationId:e.conversationId,userId:e.userId,parentWorkflowId:e.parentWorkflowId,statuses:e.statuses,name:e.name},params:{},body:{}});var xu=e=>({path:"/v1/chat/workflows/get-or-create",headers:{},query:{},params:{},body:{name:e.name,input:e.input,parentWorkflowId:e.parentWorkflowId,conversationId:e.conversationId,userId:e.userId,timeoutAt:e.timeoutAt,tags:e.tags,status:e.status,eventId:e.eventId,discriminateByTags:e.discriminateByTags,discriminateByStatusGroup:e.discriminateByStatusGroup}});var Pu=e=>({path:`/v1/chat/tags/${encodeURIComponent(e.key)}/values`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,type:e.type},params:{key:e.key},body:{}});var Au=e=>({path:"/v1/chat/analytics",headers:{},query:{},params:{},body:{name:e.name,count:e.count}});var Bu=e=>({path:"/v1/chat/observations",headers:{},query:{},params:{},body:{id:e.id,name:e.name,data:e.data,messageId:e.messageId,eventId:e.eventId,conversationId:e.conversationId,userId:e.userId,errorId:e.errorId,traceId:e.traceId}});var At=class{constructor(t,s={}){this.httpClient=t;this.props=s}createConversation=async t=>{let{path:s,headers:n,query:a,body:o}=Vi(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getConversation=async t=>{let{path:s,headers:n,query:a,body:o}=Ki(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listConversations=async t=>{let{path:s,headers:n,query:a,body:o}=zi(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateConversation=async t=>{let{path:s,headers:n,query:a,body:o}=ji(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateConversation=async t=>{let{path:s,headers:n,query:a,body:o}=Zi(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteConversation=async t=>{let{path:s,headers:n,query:a,body:o}=ep(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listParticipants=async t=>{let{path:s,headers:n,query:a,body:o}=rp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};addParticipant=async t=>{let{path:s,headers:n,query:a,body:o}=np(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getParticipant=async t=>{let{path:s,headers:n,query:a,body:o}=op(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};removeParticipant=async t=>{let{path:s,headers:n,query:a,body:o}=pp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createEvent=async t=>{let{path:s,headers:n,query:a,body:o}=cp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getEvent=async t=>{let{path:s,headers:n,query:a,body:o}=lp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listEvents=async t=>{let{path:s,headers:n,query:a,body:o}=yp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};cancelScheduledEvent=async t=>{let{path:s,headers:n,query:a,body:o}=Rp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createMessage=async t=>{let{path:s,headers:n,query:a,body:o}=hp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateMessage=async t=>{let{path:s,headers:n,query:a,body:o}=fp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getMessage=async t=>{let{path:s,headers:n,query:a,body:o}=xp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateMessage=async t=>{let{path:s,headers:n,query:a,body:o}=Pp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listMessages=async t=>{let{path:s,headers:n,query:a,body:o}=Ap(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteMessage=async t=>{let{path:s,headers:n,query:a,body:o}=Bp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};initializeIncomingMessage=async t=>{let{path:s,headers:n,query:a,body:o}=wp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};importMessages=async t=>{let{path:s,headers:n,query:a,body:o}=Gp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createUser=async t=>{let{path:s,headers:n,query:a,body:o}=Ep(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getUser=async t=>{let{path:s,headers:n,query:a,body:o}=Wp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsers=async t=>{let{path:s,headers:n,query:a,body:o}=Hp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateUser=async t=>{let{path:s,headers:n,query:a,body:o}=Dp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateUser=async t=>{let{path:s,headers:n,query:a,body:o}=Mp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteUser=async t=>{let{path:s,headers:n,query:a,body:o}=Vp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setStateExpiry=async t=>{let{path:s,headers:n,query:a,body:o}=Kp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getState=async t=>{let{path:s,headers:n,query:a,body:o}=zp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setState=async t=>{let{path:s,headers:n,query:a,body:o}=jp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrSetState=async t=>{let{path:s,headers:n,query:a,body:o}=Zp(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};patchState=async t=>{let{path:s,headers:n,query:a,body:o}=eu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"patch",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};callAction=async t=>{let{path:s,headers:n,query:a,body:o}=ru(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};unlinkIntegrationIdentifier=async t=>{let{path:s,headers:n,query:a,body:o}=nu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationIdentifierAvailability=async t=>{let{path:s,headers:n,query:a,body:o}=ou(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationInstanceIdentifiers=async t=>{let{path:s,headers:n,query:a,body:o}=pu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};configureIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=cu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=lu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=yu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=Ru(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=hu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkflows=async t=>{let{path:s,headers:n,query:a,body:o}=fu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=xu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listTagValues=async t=>{let{path:s,headers:n,query:a,body:o}=Pu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};trackAnalytics=async t=>{let{path:s,headers:n,query:a,body:o}=Au(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};captureObservation=async t=>{let{path:s,headers:n,query:a,body:o}=Bu(t),i=this.props.toRequest??b,p=this.props.toApiError??f,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})}};function f(e){let t=e?.response?.data;return t?Gr(t):Gr(e)}var Is=class extends At{config;constructor(t){let s=$.getClientConfig(t),n=W.createHttpClient(s);super(n,{toApiError:z.toApiError}),t.retry&&(n.retry=t.retry),this.config=s}get list(){return{conversations:t=>new R.AsyncCollection(({nextToken:s})=>this.listConversations({nextToken:s,...t}).then(n=>({...n,items:n.conversations}))),participants:t=>new R.AsyncCollection(({nextToken:s})=>this.listParticipants({nextToken:s,...t}).then(n=>({...n,items:n.participants}))),events:t=>new R.AsyncCollection(({nextToken:s})=>this.listEvents({nextToken:s,...t}).then(n=>({...n,items:n.events}))),messages:t=>new R.AsyncCollection(({nextToken:s})=>this.listMessages({nextToken:s,...t}).then(n=>({...n,items:n.messages}))),users:t=>new R.AsyncCollection(({nextToken:s})=>this.listUsers({nextToken:s,...t}).then(n=>({...n,items:n.users})))}}};var Hg={};te(Hg,{Client:()=>zs});var $A={getRandomValues:e=>new Uint8Array(e.map(()=>Math.floor(Math.random()*256)))},zA=typeof globalThis.crypto<"u"&&typeof globalThis.crypto.getRandomValues=="function"?globalThis.crypto:$A,w=class e extends Error{constructor(s,n,a,o,i,p,u){super(o);this.code=s;this.description=n;this.type=a;this.message=o;this.error=i;this.id=p;this.metadata=u;this.id||(this.id=e.generateId())}isApiError=!0;format(){return`[${this.type}] ${this.message} (Error ID: ${this.id})`}toJSON(){return{id:this.id,code:this.code,type:this.type,message:this.message,metadata:this.metadata}}static generateId(){let s=this.getPrefix(),n=new Date().toISOString().replace(/[\-:TZ]/g,"").split(".")[0],a=4,o=Array.from(zA.getRandomValues(new Uint8Array(a))).map(i=>i.toString(16).padStart(2,"0")).join("").toUpperCase();return`${s}_${n}x${o}`}static getPrefix(){return typeof window<"u"&&typeof window.document<"u"?"err_bwsr":"err"}},JA=e=>typeof e=="object"&&!Array.isArray(e)&&e!==null,jA=e=>e instanceof w||JA(e)&&e.isApiError===!0,ke=class extends w{constructor(t,s,n,a){super(500,"An unknown error occurred","Unknown",t,s,n,a)}},xs=class extends w{constructor(t,s,n,a){super(500,"An internal error occurred","Internal",t,s,n,a)}},ks=class extends w{constructor(t,s,n,a){super(401,"The request requires to be authenticated.","Unauthorized",t,s,n,a)}},Ps=class extends w{constructor(t,s,n,a){super(403,"The requested action can't be peform by this resource.","Forbidden",t,s,n,a)}},vs=class extends w{constructor(t,s,n,a){super(413,"The request payload is too large.","PayloadTooLarge",t,s,n,a)}},As=class extends w{constructor(t,s,n,a){super(400,"The request payload is invalid.","InvalidPayload",t,s,n,a)}},Cs=class extends w{constructor(t,s,n,a){super(415,"The request is invalid because the content-type is not supported.","UnsupportedMediaType",t,s,n,a)}},Bs=class extends w{constructor(t,s,n,a){super(405,"The requested method does not exist.","MethodNotFound",t,s,n,a)}},Ts=class extends w{constructor(t,s,n,a){super(404,"The requested resource does not exist.","ResourceNotFound",t,s,n,a)}},ws=class extends w{constructor(t,s,n,a){super(400,"The provided JSON schema is invalid.","InvalidJsonSchema",t,s,n,a)}},Us=class extends w{constructor(t,s,n,a){super(400,"The provided data doesn't respect the provided JSON schema.","InvalidDataFormat",t,s,n,a)}},Gs=class extends w{constructor(t,s,n,a){super(400,"The provided identifier is not valid. An identifier must start with a lowercase letter, be between 2 and 100 characters long and use only alphanumeric characters.","InvalidIdentifier",t,s,n,a)}},Ss=class extends w{constructor(t,s,n,a){super(409,"The resource is related with a different resource that the one referenced in the request. This is usually caused when providing two resource identifiers that aren't linked together.","RelationConflict",t,s,n,a)}},Es=class extends w{constructor(t,s,n,a){super(409,"The resource cannot be deleted because it's referenced by another resource","ReferenceConstraint",t,s,n,a)}},Ls=class extends w{constructor(t,s,n,a){super(409,"The resource is current locked and cannot be operated on until the lock is released.","ResourceLockedConflict",t,s,n,a)}},Ws=class extends w{constructor(t,s,n,a){super(410,"The requested resource is no longer available.","ResourceGone",t,s,n,a)}},_s=class extends w{constructor(t,s,n,a){super(400,"The provided resource reference is missing. This is usually caused when providing an invalid id inside the payload of a request.","ReferenceNotFound",t,s,n,a)}},Hs=class extends w{constructor(t,s,n,a){super(400,"The provided query is invalid. This is usually caused when providing an invalid parameter for querying a resource.","InvalidQuery",t,s,n,a)}},Qs=class extends w{constructor(t,s,n,a){super(400,"An error happened during the execution of a runtime (bot or integration).","Runtime",t,s,n,a)}},Ds=class extends w{constructor(t,s,n,a){super(409,"The record attempted to be created already exists.","AlreadyExists",t,s,n,a)}},Fs=class extends w{constructor(t,s,n,a){super(429,"The request has been rate limited.","RateLimited",t,s,n,a)}},Ms=class extends w{constructor(t,s,n,a){super(402,"A payment is required to perform this request.","PaymentRequired",t,s,n,a)}},Os=class extends w{constructor(t,s,n,a){super(403,"The request exceeds the allowed quota. Quotas are a soft limit that can be increased.","QuotaExceeded",t,s,n,a)}},Vs=class extends w{constructor(t,s,n,a){super(413,"The request exceeds the allowed limit. Limits are a hard limit that cannot be increased.","LimitExceeded",t,s,n,a)}},Ns=class extends w{constructor(t,s,n,a){super(400,"Request payload contains breaking changes which is not allowed for this resource without a version increment.","BreakingChanges",t,s,n,a)}},Ks=class extends w{constructor(t,s,n,a){super(504,"The operation timed out.","OperationTimeout",t,s,n,a)}},YA={Unknown:ke,Internal:xs,Unauthorized:ks,Forbidden:Ps,PayloadTooLarge:vs,InvalidPayload:As,UnsupportedMediaType:Cs,MethodNotFound:Bs,ResourceNotFound:Ts,InvalidJsonSchema:ws,InvalidDataFormat:Us,InvalidIdentifier:Gs,RelationConflict:Ss,ReferenceConstraint:Es,ResourceLockedConflict:Ls,ResourceGone:Ws,ReferenceNotFound:_s,InvalidQuery:Hs,Runtime:Qs,AlreadyExists:Ds,RateLimited:Fs,PaymentRequired:Ms,QuotaExceeded:Os,LimitExceeded:Vs,BreakingChanges:Ns,OperationTimeout:Ks},$s=e=>jA(e)?e:e instanceof Error?new ke(e.message,e):typeof e=="string"?new ke(e):ZA(e);function ZA(e){if(typeof e=="object"&&"code"in e&&"type"in e&&"id"in e&&"message"in e&&typeof e.type=="string"&&typeof e.message=="string"){let t=YA[e.type];return t?new t(e.message,void 0,e.id||"UNKNOWN",e.metadata):new ke(`An unclassified API error occurred: ${e.message} (Type: ${e.type}, Code: ${e.code})`)}return new ke("An invalid error occurred: "+JSON.stringify(e))}var Uu=Te(xe()),XA=e=>e[1]!==void 0,l=e=>{let{method:t,path:s,query:n,headers:a,body:o}=e,i=Object.entries(a).filter(XA),p=Object.fromEntries(i),u=Uu.default.stringify(n,{encode:!0,arrayFormat:"repeat",allowDots:!0}),r=u?[s,u].join("?"):s,y=["put","post","delete","patch"].includes(t.toLowerCase())?o:void 0;return{method:t,url:r,headers:p,data:y}};var Gu=e=>({path:"/v1/admin/helper/vrl",headers:{},query:{},params:{},body:{data:e.data,script:e.script}});var Eu=e=>({path:"/v1/admin/account/me",headers:{},query:{},params:{},body:{}});var Wu=e=>({path:"/v1/admin/account/me",headers:{},query:{},params:{},body:{displayName:e.displayName,profilePicture:e.profilePicture,refresh:e.refresh}});var Hu=e=>({path:"/v1/admin/account/me",headers:{},query:{},params:{},body:{}});var Du=e=>({path:"/v1/admin/account/pats",headers:{},query:{},params:{},body:{}});var Mu=e=>({path:"/v1/admin/account/pats",headers:{},query:{},params:{},body:{note:e.note}});var Vu=e=>({path:`/v1/admin/account/pats/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Ku=e=>({path:`/v1/admin/account/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{value:e.value}});var zu=e=>({path:`/v1/admin/account/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{}});var ju=e=>({path:"/v1/admin/hub/integrations",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,limit:e.limit,name:e.name,version:e.version,interfaceId:e.interfaceId,interfaceName:e.interfaceName,installedByBotId:e.installedByBotId,verificationStatus:e.verificationStatus,search:e.search,sortBy:e.sortBy,direction:e.direction},params:{},body:{}});var Zu=e=>({path:`/v1/admin/hub/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var ec=e=>({path:`/v1/admin/hub/integrations/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var rc=e=>({path:"/v1/admin/hub/plugins",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var nc=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var oc=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.id)}/dereferenced`,headers:{},query:{interfaces:e.interfaces},params:{id:e.id},body:{}});var pc=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var cc=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.id)}/code/${encodeURIComponent(e.platform)}`,headers:{},query:{},params:{id:e.id,platform:e.platform},body:{}});var lc=e=>({path:"/v1/admin/hub/interfaces",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var yc=e=>({path:`/v1/admin/hub/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Rc=e=>({path:`/v1/admin/hub/interfaces/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var hc=e=>({path:"/v1/admin/bots",headers:{},query:{},params:{},body:{states:e.states,events:e.events,recurringEvents:e.recurringEvents,actions:e.actions,configuration:e.configuration,user:e.user,conversation:e.conversation,message:e.message,tags:e.tags,maxExecutionTime:e.maxExecutionTime,subscriptions:e.subscriptions,code:e.code,name:e.name,description:e.description,medias:e.medias,url:e.url,secrets:e.secrets,dev:e.dev,type:e.type,moduleFormat:e.moduleFormat}});var fc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{url:e.url,authentication:e.authentication,configuration:e.configuration,maxExecutionTime:e.maxExecutionTime,blocked:e.blocked,alwaysAlive:e.alwaysAlive,tags:e.tags,user:e.user,message:e.message,conversation:e.conversation,events:e.events,actions:e.actions,states:e.states,recurringEvents:e.recurringEvents,integrations:e.integrations,plugins:e.plugins,subscriptions:e.subscriptions,code:e.code,name:e.name,description:e.description,medias:e.medias,secrets:e.secrets,layers:e.layers,type:e.type,moduleFormat:e.moduleFormat}});var xc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/signing-secrets/rotate`,headers:{},query:{},params:{id:e.id},body:{}});var Pc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/transfer`,headers:{},query:{},params:{id:e.id},body:{targetWorkspaceId:e.targetWorkspaceId}});var Ac=e=>({path:"/v1/admin/bots",headers:{},query:{dev:e.dev,tags:e.tags,integrationNames:e.integrationNames,pluginNames:e.pluginNames,nextToken:e.nextToken,pageSize:e.pageSize,sortField:e.sortField,sortDirection:e.sortDirection},params:{},body:{}});var Bc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var wc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Gc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/logs`,headers:{},query:{timeStart:e.timeStart,timeEnd:e.timeEnd,level:e.level,userId:e.userId,workflowId:e.workflowId,conversationId:e.conversationId,messageContains:e.messageContains,nextToken:e.nextToken},params:{id:e.id},body:{}});var Ec=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/webchat`,headers:{},query:{type:e.type},params:{id:e.id},body:{}});var Wc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/analytics`,headers:{},query:{startDate:e.startDate,endDate:e.endDate},params:{id:e.id},body:{}});var Hc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/action-runs`,headers:{},query:{integrationName:e.integrationName,timestampFrom:e.timestampFrom,timestampUntil:e.timestampUntil,nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var Dc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues/${encodeURIComponent(e.issueId)}`,headers:{},query:{},params:{id:e.id,issueId:e.issueId},body:{}});var Mc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var Vc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues/${encodeURIComponent(e.issueId)}`,headers:{},query:{},params:{id:e.id,issueId:e.issueId},body:{}});var Kc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues/${encodeURIComponent(e.issueId)}/events`,headers:{},query:{},params:{id:e.id,issueId:e.issueId},body:{}});var zc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions`,headers:{},query:{},params:{id:e.id},body:{}});var jc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions/${encodeURIComponent(e.versionId)}`,headers:{},query:{},params:{id:e.id,versionId:e.versionId},body:{}});var Zc=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/bot-json`,headers:{},query:{},params:{id:e.id},body:{}});var ed=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/publish-from-bot-json`,headers:{},query:{},params:{id:e.id},body:{botJson:e.botJson}});var rd=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions`,headers:{},query:{},params:{id:e.id},body:{name:e.name,description:e.description}});var nd=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions/deploy`,headers:{},query:{},params:{id:e.id},body:{versionId:e.versionId}});var od=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/shareable-id`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var pd=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/shareable-id`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var cd=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/shareable-id`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var ld=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/sandboxed-conversations`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var yd=e=>({path:"/v1/admin/bots/baks",headers:{},query:{botId:e.botId},params:{},body:{}});var Rd=e=>({path:"/v1/admin/bots/baks",headers:{},query:{},params:{},body:{botId:e.botId,note:e.note}});var hd=e=>({path:`/v1/admin/bots/baks/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var fd=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/allowlist`,headers:{},query:{},params:{botId:e.botId},body:{}});var xd=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/allowlist`,headers:{},query:{},params:{botId:e.botId},body:{setting:e.setting,users:e.users}});var Pd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/migrate-to-v4`,headers:{},query:{},params:{id:e.id},body:{}});var Ad=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/billing/invoices`,headers:{},query:{},params:{id:e.id},body:{}});var Bd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/billing/upcoming-invoice`,headers:{},query:{},params:{id:e.id},body:{}});var wd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/billing/invoices/charge-unpaid`,headers:{},query:{},params:{id:e.id},body:{invoiceIds:e.invoiceIds}});var Gd=e=>({path:"/v1/admin/workspaces",headers:{},query:{},params:{},body:{name:e.name,billingVersion:e.billingVersion}});var Ed=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/public`,headers:{},query:{},params:{id:e.id},body:{}});var Wd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Hd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/usages`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var Dd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/usages/by-bot`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var Md=e=>({path:"/v1/admin/workspaces/usages/quota-completion",headers:{},query:{},params:{},body:{}});var Vd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/quota`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var Kd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/quotas`,headers:{},query:{period:e.period},params:{id:e.id},body:{}});var zd=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{name:e.name,spendingLimit:e.spendingLimit,about:e.about,profilePicture:e.profilePicture,contactEmail:e.contactEmail,website:e.website,socialAccounts:e.socialAccounts,isPublic:e.isPublic,handle:e.handle}});var jd=e=>({path:"/v1/admin/workspaces/handle-availability",headers:{},query:{},params:{},body:{handle:e.handle}});var Zd=e=>({path:"/v1/admin/workspaces",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,handle:e.handle},params:{},body:{}});var el=e=>({path:"/v1/admin/workspaces/public",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,workspaceIds:e.workspaceIds,search:e.search},params:{},body:{}});var rl=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var nl=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/audit-records`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var ol=e=>({path:`/v1/admin/workspaces/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{value:e.value}});var pl=e=>({path:`/v1/admin/workspaces/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{}});var cl=e=>({path:"/v1/admin/workspace-members",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{},body:{}});var ll=e=>({path:"/v1/admin/workspace-members/me",headers:{},query:{},params:{},body:{}});var yl=e=>({path:`/v1/admin/workspace-members/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Rl=e=>({path:"/v1/admin/workspace-members",headers:{},query:{},params:{},body:{email:e.email,role:e.role,sendEmail:e.sendEmail}});var hl=e=>({path:`/v1/admin/workspace-members/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{role:e.role}});var fl=e=>({path:"/v1/admin/integrations/iaks",headers:{},query:{integrationId:e.integrationId},params:{},body:{}});var xl=e=>({path:"/v1/admin/integrations/iaks",headers:{},query:{},params:{},body:{integrationId:e.integrationId,note:e.note}});var Pl=e=>({path:`/v1/admin/integrations/iaks/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Al=e=>({path:"/v1/admin/integrations",headers:{},query:{},params:{},body:{name:e.name,version:e.version,configuration:e.configuration,configurations:e.configurations,states:e.states,events:e.events,actions:e.actions,entities:e.entities,identifier:e.identifier,channels:e.channels,user:e.user,interfaces:e.interfaces,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,secrets:e.secrets,code:e.code,url:e.url,dev:e.dev,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,layers:e.layers,attributes:e.attributes}});var Bl=e=>({path:"/v1/admin/integrations/validate",headers:{},query:{},params:{},body:{name:e.name,version:e.version,configuration:e.configuration,configurations:e.configurations,states:e.states,events:e.events,actions:e.actions,entities:e.entities,identifier:e.identifier,channels:e.channels,user:e.user,interfaces:e.interfaces,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,secrets:e.secrets,code:e.code,url:e.url,dev:e.dev,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,layers:e.layers,attributes:e.attributes}});var wl=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{configuration:e.configuration,configurations:e.configurations,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,channels:e.channels,maxExecutionTime:e.maxExecutionTime,identifier:e.identifier,actions:e.actions,events:e.events,states:e.states,user:e.user,entities:e.entities,interfaces:e.interfaces,attributes:e.attributes,secrets:e.secrets,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,url:e.url,public:e.public,visibility:e.visibility,layers:e.layers}});var Gl=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}/signing-secrets/rotate`,headers:{},query:{},params:{id:e.id},body:{}});var El=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}/validate`,headers:{},query:{},params:{id:e.id},body:{configuration:e.configuration,configurations:e.configurations,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,channels:e.channels,maxExecutionTime:e.maxExecutionTime,identifier:e.identifier,actions:e.actions,events:e.events,states:e.states,user:e.user,entities:e.entities,interfaces:e.interfaces,attributes:e.attributes,secrets:e.secrets,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,url:e.url,public:e.public,visibility:e.visibility,layers:e.layers}});var Wl=e=>({path:"/v1/admin/integrations",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,limit:e.limit,name:e.name,version:e.version,interfaceId:e.interfaceId,interfaceName:e.interfaceName,installedByBotId:e.installedByBotId,verificationStatus:e.verificationStatus,search:e.search,sortBy:e.sortBy,direction:e.direction,visibility:e.visibility,dev:e.dev},params:{},body:{}});var Hl=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Dl=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}/logs`,headers:{},query:{timeStart:e.timeStart,timeEnd:e.timeEnd,level:e.level,userId:e.userId,conversationId:e.conversationId,messageContains:e.messageContains,nextToken:e.nextToken},params:{id:e.id},body:{}});var Ml=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var Vl=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Kl=e=>({path:"/v1/admin/integrations/request-verification",headers:{},query:{},params:{},body:{integrationId:e.integrationId}});var zl=e=>({path:"/v1/admin/interfaces",headers:{},query:{},params:{},body:{name:e.name,version:e.version,entities:e.entities,events:e.events,actions:e.actions,channels:e.channels,nameTemplate:e.nameTemplate,sdkVersion:e.sdkVersion,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,attributes:e.attributes}});var jl=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Zl=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var eg=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{entities:e.entities,events:e.events,actions:e.actions,channels:e.channels,nameTemplate:e.nameTemplate,sdkVersion:e.sdkVersion,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,attributes:e.attributes}});var rg=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var ng=e=>({path:"/v1/admin/interfaces",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var og=e=>({path:"/v1/admin/plugins",headers:{},query:{},params:{},body:{name:e.name,version:e.version,configuration:e.configuration,states:e.states,events:e.events,actions:e.actions,user:e.user,conversation:e.conversation,message:e.message,sdkVersion:e.sdkVersion,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,dependencies:e.dependencies,attributes:e.attributes}});var pg=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var cg=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}/dereferenced`,headers:{},query:{interfaces:e.interfaces},params:{id:e.id},body:{}});var lg=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var yg=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{configuration:e.configuration,states:e.states,events:e.events,actions:e.actions,user:e.user,conversation:e.conversation,message:e.message,sdkVersion:e.sdkVersion,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,dependencies:e.dependencies,attributes:e.attributes}});var Rg=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var hg=e=>({path:"/v1/admin/plugins",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var fg=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}/code/${encodeURIComponent(e.platform)}`,headers:{},query:{},params:{id:e.id,platform:e.platform},body:{}});var xg=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var Pg=e=>({path:"/v1/admin/usages/multiple",headers:{},query:{types:e.types,ids:e.ids,period:e.period},params:{},body:{}});var Ag=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}/history`,headers:{},query:{type:e.type},params:{id:e.id},body:{}});var Bg=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}/activity`,headers:{},query:{type:e.type,timestampFrom:e.timestampFrom,timestampUntil:e.timestampUntil,nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var wg=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}/daily-activity`,headers:{},query:{type:e.type,dateFrom:e.dateFrom,dateUntil:e.dateUntil,nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var Gg=e=>({path:"/v1/admin/quotas/ai-spend",headers:{},query:{},params:{},body:{monthlySpendingLimit:e.monthlySpendingLimit}});var Eg=e=>({path:"/v1/admin/activities",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,taskId:e.taskId,botId:e.botId},params:{},body:{}});var Wg=e=>({path:"/v1/admin/introspect",headers:{},query:{},params:{},body:{botId:e.botId}});var Ct=class{constructor(t,s={}){this.httpClient=t;this.props=s}runVrl=async t=>{let{path:s,headers:n,query:a,body:o}=Gu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAccount=async t=>{let{path:s,headers:n,query:a,body:o}=Eu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateAccount=async t=>{let{path:s,headers:n,query:a,body:o}=Wu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteAccount=async t=>{let{path:s,headers:n,query:a,body:o}=Hu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPersonalAccessTokens=async t=>{let{path:s,headers:n,query:a,body:o}=Du(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createPersonalAccessToken=async t=>{let{path:s,headers:n,query:a,body:o}=Mu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deletePersonalAccessToken=async t=>{let{path:s,headers:n,query:a,body:o}=Vu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setAccountPreference=async t=>{let{path:s,headers:n,query:a,body:o}=Ku(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAccountPreference=async t=>{let{path:s,headers:n,query:a,body:o}=zu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicIntegrations=async t=>{let{path:s,headers:n,query:a,body:o}=ju(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicIntegrationById=async t=>{let{path:s,headers:n,query:a,body:o}=Zu(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=ec(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicPlugins=async t=>{let{path:s,headers:n,query:a,body:o}=rc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicPluginById=async t=>{let{path:s,headers:n,query:a,body:o}=nc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getDereferencedPublicPluginById=async t=>{let{path:s,headers:n,query:a,body:o}=oc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=pc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicPluginCode=async t=>{let{path:s,headers:n,query:a,body:o}=cc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicInterfaces=async t=>{let{path:s,headers:n,query:a,body:o}=lc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicInterfaceById=async t=>{let{path:s,headers:n,query:a,body:o}=yc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicInterface=async t=>{let{path:s,headers:n,query:a,body:o}=Rc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createBot=async t=>{let{path:s,headers:n,query:a,body:o}=hc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateBot=async t=>{let{path:s,headers:n,query:a,body:o}=fc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};rotateBotSigningSecrets=async t=>{let{path:s,headers:n,query:a,body:o}=xc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};transferBot=async t=>{let{path:s,headers:n,query:a,body:o}=Pc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBots=async t=>{let{path:s,headers:n,query:a,body:o}=Ac(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBot=async t=>{let{path:s,headers:n,query:a,body:o}=Bc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteBot=async t=>{let{path:s,headers:n,query:a,body:o}=wc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotLogs=async t=>{let{path:s,headers:n,query:a,body:o}=Gc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotWebchat=async t=>{let{path:s,headers:n,query:a,body:o}=Ec(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotAnalytics=async t=>{let{path:s,headers:n,query:a,body:o}=Wc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listActionRuns=async t=>{let{path:s,headers:n,query:a,body:o}=Hc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotIssue=async t=>{let{path:s,headers:n,query:a,body:o}=Dc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotIssues=async t=>{let{path:s,headers:n,query:a,body:o}=Mc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteBotIssue=async t=>{let{path:s,headers:n,query:a,body:o}=Vc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotIssueEvents=async t=>{let{path:s,headers:n,query:a,body:o}=Kc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotVersions=async t=>{let{path:s,headers:n,query:a,body:o}=zc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotVersion=async t=>{let{path:s,headers:n,query:a,body:o}=jc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotJson=async t=>{let{path:s,headers:n,query:a,body:o}=Zc(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};publishFromBotJson=async t=>{let{path:s,headers:n,query:a,body:o}=ed(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createBotVersion=async t=>{let{path:s,headers:n,query:a,body:o}=rd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deployBotVersion=async t=>{let{path:s,headers:n,query:a,body:o}=nd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createIntegrationShareableId=async t=>{let{path:s,headers:n,query:a,body:o}=od(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteIntegrationShareableId=async t=>{let{path:s,headers:n,query:a,body:o}=pd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationShareableId=async t=>{let{path:s,headers:n,query:a,body:o}=cd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};unlinkSandboxedConversations=async t=>{let{path:s,headers:n,query:a,body:o}=ld(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotApiKeys=async t=>{let{path:s,headers:n,query:a,body:o}=yd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createBotApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=Rd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteBotApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=hd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotAllowlist=async t=>{let{path:s,headers:n,query:a,body:o}=fd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateBotAllowlist=async t=>{let{path:s,headers:n,query:a,body:o}=xd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};migrateWorkspaceToV4=async t=>{let{path:s,headers:n,query:a,body:o}=Pd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceInvoices=async t=>{let{path:s,headers:n,query:a,body:o}=Ad(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getUpcomingInvoice=async t=>{let{path:s,headers:n,query:a,body:o}=Bd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};chargeWorkspaceUnpaidInvoices=async t=>{let{path:s,headers:n,query:a,body:o}=wd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=Gd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=Ed(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=Wd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceUsages=async t=>{let{path:s,headers:n,query:a,body:o}=Hd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};breakDownWorkspaceUsageByBot=async t=>{let{path:s,headers:n,query:a,body:o}=Dd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAllWorkspaceQuotaCompletion=async t=>{let{path:s,headers:n,query:a,body:o}=Md(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspaceQuota=async t=>{let{path:s,headers:n,query:a,body:o}=Vd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceQuotas=async t=>{let{path:s,headers:n,query:a,body:o}=Kd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=zd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};checkHandleAvailability=async t=>{let{path:s,headers:n,query:a,body:o}=jd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaces=async t=>{let{path:s,headers:n,query:a,body:o}=Zd(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicWorkspaces=async t=>{let{path:s,headers:n,query:a,body:o}=el(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=rl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAuditRecords=async t=>{let{path:s,headers:n,query:a,body:o}=nl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setWorkspacePreference=async t=>{let{path:s,headers:n,query:a,body:o}=ol(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspacePreference=async t=>{let{path:s,headers:n,query:a,body:o}=pl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceMembers=async t=>{let{path:s,headers:n,query:a,body:o}=cl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=ll(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=yl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=Rl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=hl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listIntegrationApiKeys=async t=>{let{path:s,headers:n,query:a,body:o}=fl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createIntegrationApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=xl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteIntegrationApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=Pl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=Al(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};validateIntegrationCreation=async t=>{let{path:s,headers:n,query:a,body:o}=Bl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=wl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};rotateIntegrationSigningSecrets=async t=>{let{path:s,headers:n,query:a,body:o}=Gl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};validateIntegrationUpdate=async t=>{let{path:s,headers:n,query:a,body:o}=El(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listIntegrations=async t=>{let{path:s,headers:n,query:a,body:o}=Wl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=Hl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationLogs=async t=>{let{path:s,headers:n,query:a,body:o}=Dl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationByName=async t=>{let{path:s,headers:n,query:a,body:o}=Ml(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=Vl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};requestIntegrationVerification=async t=>{let{path:s,headers:n,query:a,body:o}=Kl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createInterface=async t=>{let{path:s,headers:n,query:a,body:o}=zl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getInterface=async t=>{let{path:s,headers:n,query:a,body:o}=jl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getInterfaceByName=async t=>{let{path:s,headers:n,query:a,body:o}=Zl(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateInterface=async t=>{let{path:s,headers:n,query:a,body:o}=eg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteInterface=async t=>{let{path:s,headers:n,query:a,body:o}=rg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listInterfaces=async t=>{let{path:s,headers:n,query:a,body:o}=ng(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=og(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=pg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getDereferencedPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=cg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPluginByName=async t=>{let{path:s,headers:n,query:a,body:o}=lg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updatePlugin=async t=>{let{path:s,headers:n,query:a,body:o}=yg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deletePlugin=async t=>{let{path:s,headers:n,query:a,body:o}=Rg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPlugins=async t=>{let{path:s,headers:n,query:a,body:o}=hg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPluginCode=async t=>{let{path:s,headers:n,query:a,body:o}=fg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getUsage=async t=>{let{path:s,headers:n,query:a,body:o}=xg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getMultipleUsages=async t=>{let{path:s,headers:n,query:a,body:o}=Pg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsageHistory=async t=>{let{path:s,headers:n,query:a,body:o}=Ag(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsageActivity=async t=>{let{path:s,headers:n,query:a,body:o}=Bg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsageActivityDaily=async t=>{let{path:s,headers:n,query:a,body:o}=wg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};changeAISpendQuota=async t=>{let{path:s,headers:n,query:a,body:o}=Gg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listActivities=async t=>{let{path:s,headers:n,query:a,body:o}=Eg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};introspect=async t=>{let{path:s,headers:n,query:a,body:o}=Wg(t),i=this.props.toRequest??l,p=this.props.toApiError??g,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})}};function g(e){let t=e?.response?.data;return t?$s(t):$s(e)}var zs=class extends Ct{config;constructor(t){let s=$.getClientConfig(t),n=W.createHttpClient(s);super(n,{toApiError:z.toApiError}),t.retry&&(n.retry=t.retry),this.config=s}get list(){return{publicIntegrations:t=>new R.AsyncCollection(({nextToken:s})=>this.listPublicIntegrations({nextToken:s,...t}).then(n=>({...n,items:n.integrations}))),bots:t=>new R.AsyncCollection(({nextToken:s})=>this.listBots({nextToken:s,...t}).then(n=>({...n,items:n.bots}))),botIssues:t=>new R.AsyncCollection(({nextToken:s})=>this.listBotIssues({nextToken:s,...t}).then(n=>({...n,items:n.issues}))),workspaces:t=>new R.AsyncCollection(({nextToken:s})=>this.listWorkspaces({nextToken:s,...t}).then(n=>({...n,items:n.workspaces}))),publicWorkspaces:t=>new R.AsyncCollection(({nextToken:s})=>this.listPublicWorkspaces({nextToken:s,...t}).then(n=>({...n,items:n.workspaces}))),workspaceMembers:t=>new R.AsyncCollection(({nextToken:s})=>this.listWorkspaceMembers({nextToken:s,...t}).then(n=>({...n,items:n.members}))),integrations:t=>new R.AsyncCollection(({nextToken:s})=>this.listIntegrations({nextToken:s,...t}).then(n=>({...n,items:n.integrations}))),interfaces:t=>new R.AsyncCollection(({nextToken:s})=>this.listInterfaces({nextToken:s,...t}).then(n=>({...n,items:n.interfaces}))),activities:t=>new R.AsyncCollection(({nextToken:s})=>this.listActivities({nextToken:s,...t}).then(n=>({...n,items:n.activities}))),usageActivity:t=>new R.AsyncCollection(({nextToken:s})=>this.listUsageActivity({nextToken:s,...t}).then(n=>({...n,items:n.data}))),usageActivityDaily:t=>new R.AsyncCollection(({nextToken:s})=>this.listUsageActivityDaily({nextToken:s,...t}).then(n=>({...n,items:n.data})))}}};var Vy={};te(Vy,{Client:()=>xn});var tC={getRandomValues:e=>new Uint8Array(e.map(()=>Math.floor(Math.random()*256)))},rC=typeof globalThis.crypto<"u"&&typeof globalThis.crypto.getRandomValues=="function"?globalThis.crypto:tC,U=class e extends Error{constructor(s,n,a,o,i,p,u){super(o);this.code=s;this.description=n;this.type=a;this.message=o;this.error=i;this.id=p;this.metadata=u;this.id||(this.id=e.generateId())}isApiError=!0;format(){return`[${this.type}] ${this.message} (Error ID: ${this.id})`}toJSON(){return{id:this.id,code:this.code,type:this.type,message:this.message,metadata:this.metadata}}static generateId(){let s=this.getPrefix(),n=new Date().toISOString().replace(/[\-:TZ]/g,"").split(".")[0],a=4,o=Array.from(rC.getRandomValues(new Uint8Array(a))).map(i=>i.toString(16).padStart(2,"0")).join("").toUpperCase();return`${s}_${n}x${o}`}static getPrefix(){return typeof window<"u"&&typeof window.document<"u"?"err_bwsr":"err"}},sC=e=>typeof e=="object"&&!Array.isArray(e)&&e!==null,nC=e=>e instanceof U||sC(e)&&e.isApiError===!0,Pe=class extends U{constructor(t,s,n,a){super(500,"An unknown error occurred","Unknown",t,s,n,a)}},Js=class extends U{constructor(t,s,n,a){super(500,"An internal error occurred","Internal",t,s,n,a)}},js=class extends U{constructor(t,s,n,a){super(401,"The request requires to be authenticated.","Unauthorized",t,s,n,a)}},Ys=class extends U{constructor(t,s,n,a){super(403,"The requested action can't be peform by this resource.","Forbidden",t,s,n,a)}},Zs=class extends U{constructor(t,s,n,a){super(413,"The request payload is too large.","PayloadTooLarge",t,s,n,a)}},Xs=class extends U{constructor(t,s,n,a){super(400,"The request payload is invalid.","InvalidPayload",t,s,n,a)}},en=class extends U{constructor(t,s,n,a){super(415,"The request is invalid because the content-type is not supported.","UnsupportedMediaType",t,s,n,a)}},tn=class extends U{constructor(t,s,n,a){super(405,"The requested method does not exist.","MethodNotFound",t,s,n,a)}},rn=class extends U{constructor(t,s,n,a){super(404,"The requested resource does not exist.","ResourceNotFound",t,s,n,a)}},sn=class extends U{constructor(t,s,n,a){super(400,"The provided JSON schema is invalid.","InvalidJsonSchema",t,s,n,a)}},nn=class extends U{constructor(t,s,n,a){super(400,"The provided data doesn't respect the provided JSON schema.","InvalidDataFormat",t,s,n,a)}},an=class extends U{constructor(t,s,n,a){super(400,"The provided identifier is not valid. An identifier must start with a lowercase letter, be between 2 and 100 characters long and use only alphanumeric characters.","InvalidIdentifier",t,s,n,a)}},on=class extends U{constructor(t,s,n,a){super(409,"The resource is related with a different resource that the one referenced in the request. This is usually caused when providing two resource identifiers that aren't linked together.","RelationConflict",t,s,n,a)}},pn=class extends U{constructor(t,s,n,a){super(409,"The resource cannot be deleted because it's referenced by another resource","ReferenceConstraint",t,s,n,a)}},un=class extends U{constructor(t,s,n,a){super(409,"The resource is current locked and cannot be operated on until the lock is released.","ResourceLockedConflict",t,s,n,a)}},cn=class extends U{constructor(t,s,n,a){super(410,"The requested resource is no longer available.","ResourceGone",t,s,n,a)}},dn=class extends U{constructor(t,s,n,a){super(400,"The provided resource reference is missing. This is usually caused when providing an invalid id inside the payload of a request.","ReferenceNotFound",t,s,n,a)}},ln=class extends U{constructor(t,s,n,a){super(400,"The provided query is invalid. This is usually caused when providing an invalid parameter for querying a resource.","InvalidQuery",t,s,n,a)}},gn=class extends U{constructor(t,s,n,a){super(400,"An error happened during the execution of a runtime (bot or integration).","Runtime",t,s,n,a)}},yn=class extends U{constructor(t,s,n,a){super(409,"The record attempted to be created already exists.","AlreadyExists",t,s,n,a)}},mn=class extends U{constructor(t,s,n,a){super(429,"The request has been rate limited.","RateLimited",t,s,n,a)}},Rn=class extends U{constructor(t,s,n,a){super(402,"A payment is required to perform this request.","PaymentRequired",t,s,n,a)}},qn=class extends U{constructor(t,s,n,a){super(403,"The request exceeds the allowed quota. Quotas are a soft limit that can be increased.","QuotaExceeded",t,s,n,a)}},hn=class extends U{constructor(t,s,n,a){super(413,"The request exceeds the allowed limit. Limits are a hard limit that cannot be increased.","LimitExceeded",t,s,n,a)}},bn=class extends U{constructor(t,s,n,a){super(400,"Request payload contains breaking changes which is not allowed for this resource without a version increment.","BreakingChanges",t,s,n,a)}},fn=class extends U{constructor(t,s,n,a){super(504,"The operation timed out.","OperationTimeout",t,s,n,a)}},aC={Unknown:Pe,Internal:Js,Unauthorized:js,Forbidden:Ys,PayloadTooLarge:Zs,InvalidPayload:Xs,UnsupportedMediaType:en,MethodNotFound:tn,ResourceNotFound:rn,InvalidJsonSchema:sn,InvalidDataFormat:nn,InvalidIdentifier:an,RelationConflict:on,ReferenceConstraint:pn,ResourceLockedConflict:un,ResourceGone:cn,ReferenceNotFound:dn,InvalidQuery:ln,Runtime:gn,AlreadyExists:yn,RateLimited:mn,PaymentRequired:Rn,QuotaExceeded:qn,LimitExceeded:hn,BreakingChanges:bn,OperationTimeout:fn},In=e=>nC(e)?e:e instanceof Error?new Pe(e.message,e):typeof e=="string"?new Pe(e):oC(e);function oC(e){if(typeof e=="object"&&"code"in e&&"type"in e&&"id"in e&&"message"in e&&typeof e.type=="string"&&typeof e.message=="string"){let t=aC[e.type];return t?new t(e.message,void 0,e.id||"UNKNOWN",e.metadata):new Pe(`An unclassified API error occurred: ${e.message} (Type: ${e.type}, Code: ${e.code})`)}return new Pe("An invalid error occurred: "+JSON.stringify(e))}var Qg=Te(xe()),iC=e=>e[1]!==void 0,C=e=>{let{method:t,path:s,query:n,headers:a,body:o}=e,i=Object.entries(a).filter(iC),p=Object.fromEntries(i),u=Qg.default.stringify(n,{encode:!0,arrayFormat:"repeat",allowDots:!0}),r=u?[s,u].join("?"):s,y=["put","post","delete","patch"].includes(t.toLowerCase())?o:void 0;return{method:t,url:r,headers:p,data:y}};var Dg=e=>({path:"/v2/billing/readonly",headers:{},query:{},params:{},body:{}});var Mg=e=>({path:"/v2/billing/address",headers:{},query:{},params:{},body:{}});var Vg=e=>({path:"/v2/billing/address",headers:{},query:{},params:{},body:{lineOne:e.lineOne,lineTwo:e.lineTwo,city:e.city,state:e.state,postalCode:e.postalCode,country:e.country}});var Kg=e=>({path:"/v2/billing/customer",headers:{},query:{},params:{},body:{}});var zg=e=>({path:"/v2/billing/customer",headers:{},query:{},params:{},body:{address:e.address,name:e.name,taxIds:e.taxIds}});var jg=e=>({path:`/v2/billing/plans/${encodeURIComponent(e.planId)}`,headers:{},query:{},params:{planId:e.planId},body:{}});var Zg=e=>({path:"/v2/billing/plans",headers:{},query:{},params:{},body:{}});var ey=e=>({path:`/v2/billing/addons/${encodeURIComponent(e.addonId)}`,headers:{},query:{},params:{addonId:e.addonId},body:{}});var ry=e=>({path:"/v2/billing/addons",headers:{},query:{},params:{},body:{}});var ny=e=>({path:"/v2/billing/subscriptions",headers:{},query:{},params:{},body:{}});var oy=e=>({path:"/v2/billing/subscriptions/preview",headers:{},query:{},params:{},body:{plan:e.plan,addons:e.addons,couponCode:e.couponCode}});var py=e=>({path:"/v2/billing/plans",headers:{},query:{},params:{},body:{planId:e.planId,interval:e.interval,testReferenceTime:e.testReferenceTime,couponCode:e.couponCode}});var cy=e=>({path:"/v2/billing/addons",headers:{},query:{},params:{},body:{addons:e.addons,couponCode:e.couponCode}});var ly=e=>({path:"/v2/billing/subscriptions/cancel",headers:{},query:{},params:{},body:{}});var yy=e=>({path:"/v2/billing/auto-recharge/settings",headers:{},query:{},params:{},body:{}});var Ry=e=>({path:"/v2/billing/auto-recharge/settings",headers:{},query:{},params:{},body:{settings:e.settings}});var hy=e=>({path:"/v2/billing/trials",headers:{},query:{},params:{},body:{}});var fy=e=>({path:"/v2/billing/trials",headers:{},query:{},params:{},body:{lengthInDays:e.lengthInDays,plan:e.plan}});var xy=e=>({path:"/v2/billing/trials",headers:{},query:{},params:{},body:{}});var Py=e=>({path:"/v2/billing/credit-grants",headers:{},query:{},params:{},body:{amount:e.amount,feature:e.feature}});var Ay=e=>({path:"/v2/billing/invoices",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{},body:{}});var By=e=>({path:`/v2/billing/invoices/${encodeURIComponent(e.invoiceId)}/pay`,headers:{},query:{},params:{invoiceId:e.invoiceId},body:{idempotencyKey:e.idempotencyKey}});var wy=e=>({path:"/v2/billing/payment-methods",headers:{},query:{},params:{},body:{}});var Gy=e=>({path:"/v2/billing/payment-methods",headers:{},query:{},params:{},body:{paymentMethodId:e.paymentMethodId}});var Ey=e=>({path:"/v2/billing/payment-methods/intent",headers:{},query:{},params:{},body:{}});var Wy=e=>({path:"/v2/billing/quotas",headers:{},query:{},params:{},body:{}});var Hy=e=>({path:"/v2/usage/workspace-usage",headers:{},query:{feature:e.feature,period:e.period},params:{},body:{}});var Dy=e=>({path:"/v2/usage/workspace-usages",headers:{},query:{period:e.period},params:{},body:{}});var My=e=>({path:"/v2/feature-gate/list",headers:{},query:{},params:{},body:{}});var Bt=class{constructor(t,s={}){this.httpClient=t;this.props=s}getBillingReadonly=async t=>{let{path:s,headers:n,query:a,body:o}=Dg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBillingAddress=async t=>{let{path:s,headers:n,query:a,body:o}=Mg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setBillingAddress=async t=>{let{path:s,headers:n,query:a,body:o}=Vg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getCustomer=async t=>{let{path:s,headers:n,query:a,body:o}=Kg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setCustomer=async t=>{let{path:s,headers:n,query:a,body:o}=zg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"patch",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPlan=async t=>{let{path:s,headers:n,query:a,body:o}=jg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPlans=async t=>{let{path:s,headers:n,query:a,body:o}=Zg(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAddon=async t=>{let{path:s,headers:n,query:a,body:o}=ey(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listAddons=async t=>{let{path:s,headers:n,query:a,body:o}=ry(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getSubscription=async t=>{let{path:s,headers:n,query:a,body:o}=ny(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};previewSubscriptionUpdate=async t=>{let{path:s,headers:n,query:a,body:o}=oy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setPlan=async t=>{let{path:s,headers:n,query:a,body:o}=py(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setAddons=async t=>{let{path:s,headers:n,query:a,body:o}=cy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"patch",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setCancelAtPeriodEnd=async t=>{let{path:s,headers:n,query:a,body:o}=ly(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAutoRechargeSettings=async t=>{let{path:s,headers:n,query:a,body:o}=yy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setAutoRechargeSettings=async t=>{let{path:s,headers:n,query:a,body:o}=Ry(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getTrials=async t=>{let{path:s,headers:n,query:a,body:o}=hy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createTrial=async t=>{let{path:s,headers:n,query:a,body:o}=fy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};removeTrial=async t=>{let{path:s,headers:n,query:a,body:o}=xy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createCreditGrant=async t=>{let{path:s,headers:n,query:a,body:o}=Py(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listInvoices=async t=>{let{path:s,headers:n,query:a,body:o}=Ay(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};payInvoice=async t=>{let{path:s,headers:n,query:a,body:o}=By(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPaymentMethod=async t=>{let{path:s,headers:n,query:a,body:o}=wy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setPaymentMethod=async t=>{let{path:s,headers:n,query:a,body:o}=Gy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createPaymentMethodIntent=async t=>{let{path:s,headers:n,query:a,body:o}=Ey(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getQuotas=async t=>{let{path:s,headers:n,query:a,body:o}=Wy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspaceUsage=async t=>{let{path:s,headers:n,query:a,body:o}=Hy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspaceUsages=async t=>{let{path:s,headers:n,query:a,body:o}=Dy(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFeatureGates=async t=>{let{path:s,headers:n,query:a,body:o}=My(t),i=this.props.toRequest??C,p=this.props.toApiError??G,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})}};function G(e){let t=e?.response?.data;return t?In(t):In(e)}var xn=class extends Bt{config;constructor(t){let s=$.getClientConfig(t),n=W.createHttpClient(s);super(n,{toApiError:z.toApiError}),t.retry&&(n.retry=t.retry),this.config=s}get list(){return{listInvoices:t=>new R.AsyncCollection(({nextToken:s})=>this.listInvoices({nextToken:s,...t}).then(n=>({...n,items:n.invoices})))}}};var km={};te(km,{Client:()=>Jn});var uC={getRandomValues:e=>new Uint8Array(e.map(()=>Math.floor(Math.random()*256)))},cC=typeof globalThis.crypto<"u"&&typeof globalThis.crypto.getRandomValues=="function"?globalThis.crypto:uC,S=class e extends Error{constructor(s,n,a,o,i,p,u){super(o);this.code=s;this.description=n;this.type=a;this.message=o;this.error=i;this.id=p;this.metadata=u;this.id||(this.id=e.generateId())}isApiError=!0;format(){return`[${this.type}] ${this.message} (Error ID: ${this.id})`}toJSON(){return{id:this.id,code:this.code,type:this.type,message:this.message,metadata:this.metadata}}static generateId(){let s=this.getPrefix(),n=new Date().toISOString().replace(/[\-:TZ]/g,"").split(".")[0],a=4,o=Array.from(cC.getRandomValues(new Uint8Array(a))).map(i=>i.toString(16).padStart(2,"0")).join("").toUpperCase();return`${s}_${n}x${o}`}static getPrefix(){return typeof window<"u"&&typeof window.document<"u"?"err_bwsr":"err"}},dC=e=>typeof e=="object"&&!Array.isArray(e)&&e!==null,lC=e=>e instanceof S||dC(e)&&e.isApiError===!0,ve=class extends S{constructor(t,s,n,a){super(500,"An unknown error occurred","Unknown",t,s,n,a)}},kn=class extends S{constructor(t,s,n,a){super(500,"An internal error occurred","Internal",t,s,n,a)}},Pn=class extends S{constructor(t,s,n,a){super(401,"The request requires to be authenticated.","Unauthorized",t,s,n,a)}},vn=class extends S{constructor(t,s,n,a){super(403,"The requested action can't be peform by this resource.","Forbidden",t,s,n,a)}},An=class extends S{constructor(t,s,n,a){super(413,"The request payload is too large.","PayloadTooLarge",t,s,n,a)}},Cn=class extends S{constructor(t,s,n,a){super(400,"The request payload is invalid.","InvalidPayload",t,s,n,a)}},Bn=class extends S{constructor(t,s,n,a){super(415,"The request is invalid because the content-type is not supported.","UnsupportedMediaType",t,s,n,a)}},Tn=class extends S{constructor(t,s,n,a){super(405,"The requested method does not exist.","MethodNotFound",t,s,n,a)}},wn=class extends S{constructor(t,s,n,a){super(404,"The requested resource does not exist.","ResourceNotFound",t,s,n,a)}},Un=class extends S{constructor(t,s,n,a){super(400,"The provided JSON schema is invalid.","InvalidJsonSchema",t,s,n,a)}},Gn=class extends S{constructor(t,s,n,a){super(400,"The provided data doesn't respect the provided JSON schema.","InvalidDataFormat",t,s,n,a)}},Sn=class extends S{constructor(t,s,n,a){super(400,"The provided identifier is not valid. An identifier must start with a lowercase letter, be between 2 and 100 characters long and use only alphanumeric characters.","InvalidIdentifier",t,s,n,a)}},En=class extends S{constructor(t,s,n,a){super(409,"The resource is related with a different resource that the one referenced in the request. This is usually caused when providing two resource identifiers that aren't linked together.","RelationConflict",t,s,n,a)}},Ln=class extends S{constructor(t,s,n,a){super(409,"The resource cannot be deleted because it's referenced by another resource","ReferenceConstraint",t,s,n,a)}},Wn=class extends S{constructor(t,s,n,a){super(409,"The resource is current locked and cannot be operated on until the lock is released.","ResourceLockedConflict",t,s,n,a)}},_n=class extends S{constructor(t,s,n,a){super(410,"The requested resource is no longer available.","ResourceGone",t,s,n,a)}},Hn=class extends S{constructor(t,s,n,a){super(400,"The provided resource reference is missing. This is usually caused when providing an invalid id inside the payload of a request.","ReferenceNotFound",t,s,n,a)}},Qn=class extends S{constructor(t,s,n,a){super(400,"The provided query is invalid. This is usually caused when providing an invalid parameter for querying a resource.","InvalidQuery",t,s,n,a)}},Dn=class extends S{constructor(t,s,n,a){super(400,"An error happened during the execution of a runtime (bot or integration).","Runtime",t,s,n,a)}},Fn=class extends S{constructor(t,s,n,a){super(409,"The record attempted to be created already exists.","AlreadyExists",t,s,n,a)}},Mn=class extends S{constructor(t,s,n,a){super(429,"The request has been rate limited.","RateLimited",t,s,n,a)}},On=class extends S{constructor(t,s,n,a){super(402,"A payment is required to perform this request.","PaymentRequired",t,s,n,a)}},Vn=class extends S{constructor(t,s,n,a){super(403,"The request exceeds the allowed quota. Quotas are a soft limit that can be increased.","QuotaExceeded",t,s,n,a)}},Nn=class extends S{constructor(t,s,n,a){super(413,"The request exceeds the allowed limit. Limits are a hard limit that cannot be increased.","LimitExceeded",t,s,n,a)}},Kn=class extends S{constructor(t,s,n,a){super(400,"Request payload contains breaking changes which is not allowed for this resource without a version increment.","BreakingChanges",t,s,n,a)}},$n=class extends S{constructor(t,s,n,a){super(504,"The operation timed out.","OperationTimeout",t,s,n,a)}},gC={Unknown:ve,Internal:kn,Unauthorized:Pn,Forbidden:vn,PayloadTooLarge:An,InvalidPayload:Cn,UnsupportedMediaType:Bn,MethodNotFound:Tn,ResourceNotFound:wn,InvalidJsonSchema:Un,InvalidDataFormat:Gn,InvalidIdentifier:Sn,RelationConflict:En,ReferenceConstraint:Ln,ResourceLockedConflict:Wn,ResourceGone:_n,ReferenceNotFound:Hn,InvalidQuery:Qn,Runtime:Dn,AlreadyExists:Fn,RateLimited:Mn,PaymentRequired:On,QuotaExceeded:Vn,LimitExceeded:Nn,BreakingChanges:Kn,OperationTimeout:$n},zn=e=>lC(e)?e:e instanceof Error?new ve(e.message,e):typeof e=="string"?new ve(e):yC(e);function yC(e){if(typeof e=="object"&&"code"in e&&"type"in e&&"id"in e&&"message"in e&&typeof e.type=="string"&&typeof e.message=="string"){let t=gC[e.type];return t?new t(e.message,void 0,e.id||"UNKNOWN",e.metadata):new ve(`An unclassified API error occurred: ${e.message} (Type: ${e.type}, Code: ${e.code})`)}return new ve("An invalid error occurred: "+JSON.stringify(e))}var Ny=Te(xe()),mC=e=>e[1]!==void 0,V=e=>{let{method:t,path:s,query:n,headers:a,body:o}=e,i=Object.entries(a).filter(mC),p=Object.fromEntries(i),u=Ny.default.stringify(n,{encode:!0,arrayFormat:"repeat",allowDots:!0}),r=u?[s,u].join("?"):s,y=["put","post","delete","patch"].includes(t.toLowerCase())?o:void 0;return{method:t,url:r,headers:p,data:y}};var Ky=e=>({path:"/v1/files",headers:{},query:{},params:{},body:{key:e.key,tags:e.tags,size:e.size,index:e.index,indexing:e.indexing,accessPolicies:e.accessPolicies,contentType:e.contentType,expiresAt:e.expiresAt,publicContentImmediatelyAccessible:e.publicContentImmediatelyAccessible,metadata:e.metadata}});var zy=e=>({path:`/v1/files/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var jy=e=>({path:"/v1/files",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,sortField:e.sortField,sortDirection:e.sortDirection,tags:e.tags,ids:e.ids,indexed:e.indexed},params:{},body:{}});var Zy=e=>({path:`/v1/files/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var em=e=>({path:`/v1/files/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{metadata:e.metadata,tags:e.tags,accessPolicies:e.accessPolicies,expiresAt:e.expiresAt}});var rm=e=>({path:`/v1/files/${encodeURIComponent(e.idOrKey)}/${encodeURIComponent(e.destinationKey)}`,headers:{"x-destination-bot-id":e["x-destination-bot-id"]},query:{},params:{idOrKey:e.idOrKey,destinationKey:e.destinationKey},body:{overwrite:e.overwrite}});var nm=e=>({path:"/v1/files/search",headers:{},query:{tags:e.tags,query:e.query,contextDepth:e.contextDepth,limit:e.limit,consolidate:e.consolidate,includeBreadcrumb:e.includeBreadcrumb,withContext:e.withContext},params:{},body:{}});var om=e=>({path:`/v1/files/${encodeURIComponent(e.id)}/passages`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,limit:e.limit},params:{id:e.id},body:{}});var pm=e=>({path:`/v1/files/${encodeURIComponent(e.id)}/passages`,headers:{},query:{},params:{id:e.id},body:{passages:e.passages}});var cm=e=>({path:"/v1/files/tags",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{},body:{}});var lm=e=>({path:`/v1/files/tags/${encodeURIComponent(e.tag)}/values`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{tag:e.tag},body:{}});var ym=e=>({path:"/v1/files/knowledge-bases",headers:{},query:{},params:{},body:{name:e.name,description:e.description,tags:e.tags}});var Rm=e=>({path:`/v1/files/knowledge-bases/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var hm=e=>({path:`/v1/files/knowledge-bases/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{name:e.name,description:e.description,tags:e.tags}});var fm=e=>({path:"/v1/files/knowledge-bases",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,tags:e.tags},params:{},body:{}});var Tt=class{constructor(t,s={}){this.httpClient=t;this.props=s}upsertFile=async t=>{let{path:s,headers:n,query:a,body:o}=Ky(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteFile=async t=>{let{path:s,headers:n,query:a,body:o}=zy(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFiles=async t=>{let{path:s,headers:n,query:a,body:o}=jy(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getFile=async t=>{let{path:s,headers:n,query:a,body:o}=Zy(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateFileMetadata=async t=>{let{path:s,headers:n,query:a,body:o}=em(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};copyFile=async t=>{let{path:s,headers:n,query:a,body:o}=rm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};searchFiles=async t=>{let{path:s,headers:n,query:a,body:o}=nm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFilePassages=async t=>{let{path:s,headers:n,query:a,body:o}=om(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setFilePassages=async t=>{let{path:s,headers:n,query:a,body:o}=pm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFileTags=async t=>{let{path:s,headers:n,query:a,body:o}=cm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFileTagValues=async t=>{let{path:s,headers:n,query:a,body:o}=lm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createKnowledgeBase=async t=>{let{path:s,headers:n,query:a,body:o}=ym(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteKnowledgeBase=async t=>{let{path:s,headers:n,query:a,body:o}=Rm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateKnowledgeBase=async t=>{let{path:s,headers:n,query:a,body:o}=hm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listKnowledgeBases=async t=>{let{path:s,headers:n,query:a,body:o}=fm(t),i=this.props.toRequest??V,p=this.props.toApiError??N,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})}};function N(e){let t=e?.response?.data;return t?zn(t):zn(e)}var wt=async(e,{key:t,index:s,tags:n,contentType:a,accessPolicies:o,content:i,url:p,indexing:u,expiresAt:r,metadata:y,publicContentImmediatelyAccessible:x})=>{if(p&&i)throw new ie("Cannot provide both content and URL, please provide only one of them");if(p&&(i=await new W.HttpClient().get(p,{responseType:"arraybuffer"}).then(L=>L.data).catch(L=>{throw new ie(`Failed to download file from provided URL: ${L.message}`,L)})),!i)throw new ie("No content was provided for the file");let m,k;if(typeof i=="string"){let I=new TextEncoder().encode(i);m=I,k=I.byteLength}else if(i instanceof Uint8Array)m=i,k=m.byteLength;else if(i instanceof ArrayBuffer)m=i,k=m.byteLength;else if(i instanceof Blob)m=i,k=i.size;else throw new ie("The provided content is not supported");let{file:P}=await e.upsertFile({key:t,tags:n,index:s,accessPolicies:o,contentType:a,metadata:y,size:k,expiresAt:r,indexing:u,publicContentImmediatelyAccessible:x}),q={"Content-Type":P.contentType};x&&(q["x-amz-tagging"]="public=true");try{await new W.HttpClient().put(P.uploadUrl,m,{headers:q})}catch(L){let I=L instanceof Error?L:new Error(String(L));throw new ie(`Failed to upload file: ${I.message}`,I,P)}return{file:{...P,size:k}}};var Jn=class extends Tt{config;constructor(t){let s=$.getClientConfig(t),n=W.createHttpClient(s);super(n,{toApiError:z.toApiError}),t.retry&&(n.retry=t.retry),this.config=s}get list(){return{files:t=>new R.AsyncCollection(({nextToken:s})=>this.listFiles({nextToken:s,...t}).then(n=>({...n,items:n.files}))),filePassages:t=>new R.AsyncCollection(({nextToken:s})=>this.listFilePassages({nextToken:s,...t}).then(n=>({...n,items:n.passages}))),fileTags:t=>new R.AsyncCollection(({nextToken:s})=>this.listFileTags({nextToken:s,...t}).then(n=>({...n,items:n.tags}))),fileTagValues:t=>new R.AsyncCollection(({nextToken:s})=>this.listFileTagValues({nextToken:s,...t}).then(n=>({...n,items:n.values}))),knowledgeBases:t=>new R.AsyncCollection(({nextToken:s})=>this.listKnowledgeBases({nextToken:s,...t}).then(n=>({...n,items:n.knowledgeBases})))}}async uploadFile(t){return await wt(this,t)}};var aR={};te(aR,{Client:()=>xa});var qC={getRandomValues:e=>new Uint8Array(e.map(()=>Math.floor(Math.random()*256)))},hC=typeof globalThis.crypto<"u"&&typeof globalThis.crypto.getRandomValues=="function"?globalThis.crypto:qC,E=class e extends Error{constructor(s,n,a,o,i,p,u){super(o);this.code=s;this.description=n;this.type=a;this.message=o;this.error=i;this.id=p;this.metadata=u;this.id||(this.id=e.generateId())}isApiError=!0;format(){return`[${this.type}] ${this.message} (Error ID: ${this.id})`}toJSON(){return{id:this.id,code:this.code,type:this.type,message:this.message,metadata:this.metadata}}static generateId(){let s=this.getPrefix(),n=new Date().toISOString().replace(/[\-:TZ]/g,"").split(".")[0],a=4,o=Array.from(hC.getRandomValues(new Uint8Array(a))).map(i=>i.toString(16).padStart(2,"0")).join("").toUpperCase();return`${s}_${n}x${o}`}static getPrefix(){return typeof window<"u"&&typeof window.document<"u"?"err_bwsr":"err"}},bC=e=>typeof e=="object"&&!Array.isArray(e)&&e!==null,fC=e=>e instanceof E||bC(e)&&e.isApiError===!0,Ae=class extends E{constructor(t,s,n,a){super(500,"An unknown error occurred","Unknown",t,s,n,a)}},jn=class extends E{constructor(t,s,n,a){super(500,"An internal error occurred","Internal",t,s,n,a)}},Yn=class extends E{constructor(t,s,n,a){super(401,"The request requires to be authenticated.","Unauthorized",t,s,n,a)}},Zn=class extends E{constructor(t,s,n,a){super(403,"The requested action can't be peform by this resource.","Forbidden",t,s,n,a)}},Xn=class extends E{constructor(t,s,n,a){super(413,"The request payload is too large.","PayloadTooLarge",t,s,n,a)}},ea=class extends E{constructor(t,s,n,a){super(400,"The request payload is invalid.","InvalidPayload",t,s,n,a)}},ta=class extends E{constructor(t,s,n,a){super(415,"The request is invalid because the content-type is not supported.","UnsupportedMediaType",t,s,n,a)}},ra=class extends E{constructor(t,s,n,a){super(405,"The requested method does not exist.","MethodNotFound",t,s,n,a)}},sa=class extends E{constructor(t,s,n,a){super(404,"The requested resource does not exist.","ResourceNotFound",t,s,n,a)}},na=class extends E{constructor(t,s,n,a){super(400,"The provided JSON schema is invalid.","InvalidJsonSchema",t,s,n,a)}},aa=class extends E{constructor(t,s,n,a){super(400,"The provided data doesn't respect the provided JSON schema.","InvalidDataFormat",t,s,n,a)}},oa=class extends E{constructor(t,s,n,a){super(400,"The provided identifier is not valid. An identifier must start with a lowercase letter, be between 2 and 100 characters long and use only alphanumeric characters.","InvalidIdentifier",t,s,n,a)}},ia=class extends E{constructor(t,s,n,a){super(409,"The resource is related with a different resource that the one referenced in the request. This is usually caused when providing two resource identifiers that aren't linked together.","RelationConflict",t,s,n,a)}},pa=class extends E{constructor(t,s,n,a){super(409,"The resource cannot be deleted because it's referenced by another resource","ReferenceConstraint",t,s,n,a)}},ua=class extends E{constructor(t,s,n,a){super(409,"The resource is current locked and cannot be operated on until the lock is released.","ResourceLockedConflict",t,s,n,a)}},ca=class extends E{constructor(t,s,n,a){super(410,"The requested resource is no longer available.","ResourceGone",t,s,n,a)}},da=class extends E{constructor(t,s,n,a){super(400,"The provided resource reference is missing. This is usually caused when providing an invalid id inside the payload of a request.","ReferenceNotFound",t,s,n,a)}},la=class extends E{constructor(t,s,n,a){super(400,"The provided query is invalid. This is usually caused when providing an invalid parameter for querying a resource.","InvalidQuery",t,s,n,a)}},ga=class extends E{constructor(t,s,n,a){super(400,"An error happened during the execution of a runtime (bot or integration).","Runtime",t,s,n,a)}},ya=class extends E{constructor(t,s,n,a){super(409,"The record attempted to be created already exists.","AlreadyExists",t,s,n,a)}},ma=class extends E{constructor(t,s,n,a){super(429,"The request has been rate limited.","RateLimited",t,s,n,a)}},Ra=class extends E{constructor(t,s,n,a){super(402,"A payment is required to perform this request.","PaymentRequired",t,s,n,a)}},qa=class extends E{constructor(t,s,n,a){super(403,"The request exceeds the allowed quota. Quotas are a soft limit that can be increased.","QuotaExceeded",t,s,n,a)}},ha=class extends E{constructor(t,s,n,a){super(413,"The request exceeds the allowed limit. Limits are a hard limit that cannot be increased.","LimitExceeded",t,s,n,a)}},ba=class extends E{constructor(t,s,n,a){super(400,"Request payload contains breaking changes which is not allowed for this resource without a version increment.","BreakingChanges",t,s,n,a)}},fa=class extends E{constructor(t,s,n,a){super(504,"The operation timed out.","OperationTimeout",t,s,n,a)}},IC={Unknown:Ae,Internal:jn,Unauthorized:Yn,Forbidden:Zn,PayloadTooLarge:Xn,InvalidPayload:ea,UnsupportedMediaType:ta,MethodNotFound:ra,ResourceNotFound:sa,InvalidJsonSchema:na,InvalidDataFormat:aa,InvalidIdentifier:oa,RelationConflict:ia,ReferenceConstraint:pa,ResourceLockedConflict:ua,ResourceGone:ca,ReferenceNotFound:da,InvalidQuery:la,Runtime:ga,AlreadyExists:ya,RateLimited:ma,PaymentRequired:Ra,QuotaExceeded:qa,LimitExceeded:ha,BreakingChanges:ba,OperationTimeout:fa},Ia=e=>fC(e)?e:e instanceof Error?new Ae(e.message,e):typeof e=="string"?new Ae(e):xC(e);function xC(e){if(typeof e=="object"&&"code"in e&&"type"in e&&"id"in e&&"message"in e&&typeof e.type=="string"&&typeof e.message=="string"){let t=IC[e.type];return t?new t(e.message,void 0,e.id||"UNKNOWN",e.metadata):new Ae(`An unclassified API error occurred: ${e.message} (Type: ${e.type}, Code: ${e.code})`)}return new Ae("An invalid error occurred: "+JSON.stringify(e))}var Pm=Te(xe()),kC=e=>e[1]!==void 0,D=e=>{let{method:t,path:s,query:n,headers:a,body:o}=e,i=Object.entries(a).filter(kC),p=Object.fromEntries(i),u=Pm.default.stringify(n,{encode:!0,arrayFormat:"repeat",allowDots:!0}),r=u?[s,u].join("?"):s,y=["put","post","delete","patch"].includes(t.toLowerCase())?o:void 0;return{method:t,url:r,headers:p,data:y}};var vm=e=>({path:"/v1/tables",headers:{},query:{tags:e.tags},params:{},body:{}});var Cm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{}});var Tm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{factor:e.factor,frozen:e.frozen,keyColumn:e.keyColumn,schema:e.schema,tags:e.tags,isComputeEnabled:e.isComputeEnabled}});var Um=e=>({path:"/v1/tables",headers:{},query:{},params:{},body:{name:e.name,factor:e.factor,frozen:e.frozen,keyColumn:e.keyColumn,schema:e.schema,tags:e.tags,isComputeEnabled:e.isComputeEnabled}});var Sm=e=>({path:`/v1/tables/${encodeURIComponent(e.sourceTableId)}/duplicate`,headers:{},query:{},params:{sourceTableId:e.sourceTableId},body:{tableName:e.tableName,schemaOnly:e.schemaOnly,factor:e.factor}});var Lm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/export`,headers:{},query:{format:e.format,compress:e.compress},params:{table:e.table},body:{}});var _m=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/jobs`,headers:{},query:{},params:{table:e.table},body:{}});var Qm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/import`,headers:{},query:{},params:{table:e.table},body:{fileId:e.fileId}});var Fm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{name:e.name,frozen:e.frozen,keyColumn:e.keyColumn,schema:e.schema,tags:e.tags,isComputeEnabled:e.isComputeEnabled,factor:e.factor}});var Om=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/column`,headers:{},query:{},params:{table:e.table},body:{name:e.name,newName:e.newName}});var Nm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{}});var $m=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/row`,headers:{},query:{id:e.id},params:{table:e.table},body:{}});var Jm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows/find`,headers:{},query:{},params:{table:e.table},body:{limit:e.limit,offset:e.offset,filter:e.filter,group:e.group,search:e.search,select:e.select,orderBy:e.orderBy,orderDirection:e.orderDirection}});var Ym=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows`,headers:{},query:{},params:{table:e.table},body:{rows:e.rows,waitComputed:e.waitComputed}});var Xm=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows/delete`,headers:{},query:{},params:{table:e.table},body:{ids:e.ids,filter:e.filter,deleteAllRows:e.deleteAllRows}});var tR=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows`,headers:{},query:{},params:{table:e.table},body:{rows:e.rows,waitComputed:e.waitComputed}});var sR=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows/upsert`,headers:{},query:{},params:{table:e.table},body:{rows:e.rows,keyColumn:e.keyColumn,waitComputed:e.waitComputed}});var Ut=class{constructor(t,s={}){this.httpClient=t;this.props=s}listTables=async t=>{let{path:s,headers:n,query:a,body:o}=vm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getTable=async t=>{let{path:s,headers:n,query:a,body:o}=Cm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateTable=async t=>{let{path:s,headers:n,query:a,body:o}=Tm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createTable=async t=>{let{path:s,headers:n,query:a,body:o}=Um(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};duplicateTable=async t=>{let{path:s,headers:n,query:a,body:o}=Sm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};exportTable=async t=>{let{path:s,headers:n,query:a,body:o}=Lm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getTableJobs=async t=>{let{path:s,headers:n,query:a,body:o}=_m(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};importTable=async t=>{let{path:s,headers:n,query:a,body:o}=Qm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateTable=async t=>{let{path:s,headers:n,query:a,body:o}=Fm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};renameTableColumn=async t=>{let{path:s,headers:n,query:a,body:o}=Om(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteTable=async t=>{let{path:s,headers:n,query:a,body:o}=Nm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getTableRow=async t=>{let{path:s,headers:n,query:a,body:o}=$m(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};findTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=Jm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=Ym(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=Xm(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=tR(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};upsertTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=sR(t),i=this.props.toRequest??D,p=this.props.toApiError??M,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})}};function M(e){let t=e?.response?.data;return t?Ia(t):Ia(e)}var xa=class extends Ut{config;constructor(t){let s=$.getClientConfig(t),n=W.createHttpClient(s);super(n,{toApiError:z.toApiError}),t.retry&&(n.retry=t.retry),this.config=s}};var oR=Te(xe()),vC=e=>e[1]!==void 0,c=e=>{let{method:t,path:s,query:n,headers:a,body:o}=e,i=Object.entries(a).filter(vC),p=Object.fromEntries(i),u=oR.default.stringify(n,{encode:!0,arrayFormat:"repeat",allowDots:!0}),r=u?[s,u].join("?"):s,y=["put","post","delete","patch"].includes(t.toLowerCase())?o:void 0;return{method:t,url:r,headers:p,data:y}};var iR=e=>({path:"/v1/chat/conversations",headers:{},query:{},params:{},body:{channel:e.channel,tags:e.tags,integrationName:e.integrationName,properties:e.properties}});var uR=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var dR=e=>({path:"/v1/chat/conversations",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,sortField:e.sortField,sortDirection:e.sortDirection,tags:e.tags,participantIds:e.participantIds,integrationName:e.integrationName,channel:e.channel,afterDate:e.afterDate,beforeDate:e.beforeDate,minMessageCount:e.minMessageCount,maxMessageCount:e.maxMessageCount},params:{},body:{}});var gR=e=>({path:"/v1/chat/conversations/get-or-create",headers:{},query:{},params:{},body:{channel:e.channel,tags:e.tags,integrationName:e.integrationName,properties:e.properties,discriminateByTags:e.discriminateByTags}});var mR=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{currentTaskId:e.currentTaskId,tags:e.tags,properties:e.properties}});var qR=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var bR=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var IR=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants`,headers:{},query:{},params:{id:e.id},body:{userId:e.userId}});var kR=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants/${encodeURIComponent(e.userId)}`,headers:{},query:{},params:{id:e.id,userId:e.userId},body:{}});var vR=e=>({path:`/v1/chat/conversations/${encodeURIComponent(e.id)}/participants/${encodeURIComponent(e.userId)}`,headers:{},query:{},params:{id:e.id,userId:e.userId},body:{}});var CR=e=>({path:"/v1/chat/events",headers:{},query:{},params:{},body:{type:e.type,payload:e.payload,schedule:e.schedule,conversationId:e.conversationId,userId:e.userId,workflowId:e.workflowId,messageId:e.messageId}});var TR=e=>({path:`/v1/chat/events/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var UR=e=>({path:"/v1/chat/events",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,type:e.type,conversationId:e.conversationId,userId:e.userId,messageId:e.messageId,workflowId:e.workflowId,status:e.status},params:{},body:{}});var SR=e=>({path:`/v1/chat/events/scheduled/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var LR=e=>({path:"/v1/chat/messages",headers:{},query:{},params:{},body:{payload:e.payload,userId:e.userId,conversationId:e.conversationId,type:e.type,tags:e.tags,schedule:e.schedule,origin:e.origin}});var _R=e=>({path:"/v1/chat/messages/get-or-create",headers:{},query:{},params:{},body:{payload:e.payload,userId:e.userId,conversationId:e.conversationId,type:e.type,tags:e.tags,schedule:e.schedule,origin:e.origin,discriminateByTags:e.discriminateByTags}});var QR=e=>({path:`/v1/chat/messages/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var FR=e=>({path:`/v1/chat/messages/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{tags:e.tags,payload:e.payload}});var OR=e=>({path:"/v1/chat/messages",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,conversationId:e.conversationId,tags:e.tags,afterDate:e.afterDate,beforeDate:e.beforeDate},params:{},body:{}});var NR=e=>({path:`/v1/chat/messages/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var $R=e=>({path:"/v1/chat/initialize-incoming-message",headers:{},query:{},params:{},body:{userId:e.userId,user:e.user,conversationId:e.conversationId,conversation:e.conversation,message:e.message}});var JR=e=>({path:"/v1/chat/messages/import-messages",headers:{},query:{},params:{},body:{messages:e.messages}});var YR=e=>({path:"/v1/chat/users",headers:{},query:{},params:{},body:{tags:e.tags,integrationName:e.integrationName,name:e.name,pictureUrl:e.pictureUrl,properties:e.properties,attributes:e.attributes}});var XR=e=>({path:`/v1/chat/users/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var tq=e=>({path:"/v1/chat/users",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,conversationId:e.conversationId,tags:e.tags,afterDate:e.afterDate,beforeDate:e.beforeDate,rangeField:e.rangeField,sortField:e.sortField,sortDirection:e.sortDirection},params:{},body:{}});var sq=e=>({path:"/v1/chat/users/get-or-create",headers:{},query:{},params:{},body:{tags:e.tags,integrationName:e.integrationName,name:e.name,pictureUrl:e.pictureUrl,properties:e.properties,attributes:e.attributes,discriminateByTags:e.discriminateByTags}});var aq=e=>({path:`/v1/chat/users/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{tags:e.tags,name:e.name,pictureUrl:e.pictureUrl,attributes:e.attributes,properties:e.properties}});var iq=e=>({path:`/v1/chat/users/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var uq=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}/expiry`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{expiry:e.expiry}});var dq=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{}});var gq=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{payload:e.payload,expiry:e.expiry}});var mq=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}/get-or-set`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{payload:e.payload,expiry:e.expiry}});var qq=e=>({path:`/v1/chat/states/${encodeURIComponent(e.type)}/${encodeURIComponent(e.id)}/${encodeURIComponent(e.name)}`,headers:{},query:{},params:{type:e.type,id:e.id,name:e.name},body:{payload:e.payload,expiry:e.expiry}});var bq=e=>({path:"/v1/chat/actions",headers:{},query:{},params:{},body:{type:e.type,input:e.input}});var Iq=e=>({path:"/v1/chat/integration/identifiers",headers:{},query:{value:e.value},params:{},body:{}});var kq=e=>({path:"/v1/chat/integration/identifiers/availability",headers:{},query:{value:e.value},params:{},body:{}});var vq=e=>({path:"/v1/chat/integration-instance/identifiers",headers:{},query:{},params:{},body:{}});var Cq=e=>({path:"/v1/chat/integrations/configure",headers:{},query:{},params:{},body:{identifier:e.identifier,identifiers:e.identifiers,scheduleRegisterCall:e.scheduleRegisterCall,sandboxIdentifiers:e.sandboxIdentifiers}});var Tq=e=>({path:"/v1/chat/workflows",headers:{},query:{},params:{},body:{name:e.name,input:e.input,parentWorkflowId:e.parentWorkflowId,conversationId:e.conversationId,userId:e.userId,timeoutAt:e.timeoutAt,tags:e.tags,status:e.status,eventId:e.eventId}});var Uq=e=>({path:`/v1/chat/workflows/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Sq=e=>({path:`/v1/chat/workflows/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{output:e.output,timeoutAt:e.timeoutAt,status:e.status,failureReason:e.failureReason,tags:e.tags,userId:e.userId,eventId:e.eventId}});var Lq=e=>({path:`/v1/chat/workflows/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var _q=e=>({path:"/v1/chat/workflows",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,tags:e.tags,conversationId:e.conversationId,userId:e.userId,parentWorkflowId:e.parentWorkflowId,statuses:e.statuses,name:e.name},params:{},body:{}});var Qq=e=>({path:"/v1/chat/workflows/get-or-create",headers:{},query:{},params:{},body:{name:e.name,input:e.input,parentWorkflowId:e.parentWorkflowId,conversationId:e.conversationId,userId:e.userId,timeoutAt:e.timeoutAt,tags:e.tags,status:e.status,eventId:e.eventId,discriminateByTags:e.discriminateByTags,discriminateByStatusGroup:e.discriminateByStatusGroup}});var Fq=e=>({path:`/v1/chat/tags/${encodeURIComponent(e.key)}/values`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,type:e.type},params:{key:e.key},body:{}});var Oq=e=>({path:"/v1/chat/analytics",headers:{},query:{},params:{},body:{name:e.name,count:e.count}});var Nq=e=>({path:"/v1/chat/observations",headers:{},query:{},params:{},body:{id:e.id,name:e.name,data:e.data,messageId:e.messageId,eventId:e.eventId,conversationId:e.conversationId,userId:e.userId,errorId:e.errorId,traceId:e.traceId}});var $q=e=>({path:"/v1/admin/helper/vrl",headers:{},query:{},params:{},body:{data:e.data,script:e.script}});var Jq=e=>({path:"/v1/admin/account/me",headers:{},query:{},params:{},body:{}});var Yq=e=>({path:"/v1/admin/account/me",headers:{},query:{},params:{},body:{displayName:e.displayName,profilePicture:e.profilePicture,refresh:e.refresh}});var Xq=e=>({path:"/v1/admin/account/me",headers:{},query:{},params:{},body:{}});var th=e=>({path:"/v1/admin/account/pats",headers:{},query:{},params:{},body:{}});var sh=e=>({path:"/v1/admin/account/pats",headers:{},query:{},params:{},body:{note:e.note}});var ah=e=>({path:`/v1/admin/account/pats/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var ih=e=>({path:`/v1/admin/account/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{value:e.value}});var uh=e=>({path:`/v1/admin/account/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{}});var dh=e=>({path:"/v1/admin/hub/integrations",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,limit:e.limit,name:e.name,version:e.version,interfaceId:e.interfaceId,interfaceName:e.interfaceName,installedByBotId:e.installedByBotId,verificationStatus:e.verificationStatus,search:e.search,sortBy:e.sortBy,direction:e.direction},params:{},body:{}});var gh=e=>({path:`/v1/admin/hub/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var mh=e=>({path:`/v1/admin/hub/integrations/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var qh=e=>({path:"/v1/admin/hub/plugins",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var bh=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Ih=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.id)}/dereferenced`,headers:{},query:{interfaces:e.interfaces},params:{id:e.id},body:{}});var kh=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var vh=e=>({path:`/v1/admin/hub/plugins/${encodeURIComponent(e.id)}/code/${encodeURIComponent(e.platform)}`,headers:{},query:{},params:{id:e.id,platform:e.platform},body:{}});var Ch=e=>({path:"/v1/admin/hub/interfaces",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var Th=e=>({path:`/v1/admin/hub/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Uh=e=>({path:`/v1/admin/hub/interfaces/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var Sh=e=>({path:"/v1/admin/bots",headers:{},query:{},params:{},body:{states:e.states,events:e.events,recurringEvents:e.recurringEvents,actions:e.actions,configuration:e.configuration,user:e.user,conversation:e.conversation,message:e.message,tags:e.tags,maxExecutionTime:e.maxExecutionTime,subscriptions:e.subscriptions,code:e.code,name:e.name,description:e.description,medias:e.medias,url:e.url,secrets:e.secrets,dev:e.dev,type:e.type,moduleFormat:e.moduleFormat}});var Lh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{url:e.url,authentication:e.authentication,configuration:e.configuration,maxExecutionTime:e.maxExecutionTime,blocked:e.blocked,alwaysAlive:e.alwaysAlive,tags:e.tags,user:e.user,message:e.message,conversation:e.conversation,events:e.events,actions:e.actions,states:e.states,recurringEvents:e.recurringEvents,integrations:e.integrations,plugins:e.plugins,subscriptions:e.subscriptions,code:e.code,name:e.name,description:e.description,medias:e.medias,secrets:e.secrets,layers:e.layers,type:e.type,moduleFormat:e.moduleFormat}});var _h=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/signing-secrets/rotate`,headers:{},query:{},params:{id:e.id},body:{}});var Qh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/transfer`,headers:{},query:{},params:{id:e.id},body:{targetWorkspaceId:e.targetWorkspaceId}});var Fh=e=>({path:"/v1/admin/bots",headers:{},query:{dev:e.dev,tags:e.tags,integrationNames:e.integrationNames,pluginNames:e.pluginNames,nextToken:e.nextToken,pageSize:e.pageSize,sortField:e.sortField,sortDirection:e.sortDirection},params:{},body:{}});var Oh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Nh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var $h=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/logs`,headers:{},query:{timeStart:e.timeStart,timeEnd:e.timeEnd,level:e.level,userId:e.userId,workflowId:e.workflowId,conversationId:e.conversationId,messageContains:e.messageContains,nextToken:e.nextToken},params:{id:e.id},body:{}});var Jh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/webchat`,headers:{},query:{type:e.type},params:{id:e.id},body:{}});var Yh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/analytics`,headers:{},query:{startDate:e.startDate,endDate:e.endDate},params:{id:e.id},body:{}});var Xh=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/action-runs`,headers:{},query:{integrationName:e.integrationName,timestampFrom:e.timestampFrom,timestampUntil:e.timestampUntil,nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var tb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues/${encodeURIComponent(e.issueId)}`,headers:{},query:{},params:{id:e.id,issueId:e.issueId},body:{}});var sb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var ab=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues/${encodeURIComponent(e.issueId)}`,headers:{},query:{},params:{id:e.id,issueId:e.issueId},body:{}});var ib=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/issues/${encodeURIComponent(e.issueId)}/events`,headers:{},query:{},params:{id:e.id,issueId:e.issueId},body:{}});var ub=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions`,headers:{},query:{},params:{id:e.id},body:{}});var db=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions/${encodeURIComponent(e.versionId)}`,headers:{},query:{},params:{id:e.id,versionId:e.versionId},body:{}});var gb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/bot-json`,headers:{},query:{},params:{id:e.id},body:{}});var mb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/publish-from-bot-json`,headers:{},query:{},params:{id:e.id},body:{botJson:e.botJson}});var qb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions`,headers:{},query:{},params:{id:e.id},body:{name:e.name,description:e.description}});var bb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.id)}/versions/deploy`,headers:{},query:{},params:{id:e.id},body:{versionId:e.versionId}});var Ib=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/shareable-id`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var kb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/shareable-id`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var vb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/shareable-id`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var Cb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/integrations/${encodeURIComponent(e.integrationId)}/sandboxed-conversations`,headers:{},query:{integrationInstanceAlias:e.integrationInstanceAlias},params:{botId:e.botId,integrationId:e.integrationId},body:{}});var Tb=e=>({path:"/v1/admin/bots/baks",headers:{},query:{botId:e.botId},params:{},body:{}});var Ub=e=>({path:"/v1/admin/bots/baks",headers:{},query:{},params:{},body:{botId:e.botId,note:e.note}});var Sb=e=>({path:`/v1/admin/bots/baks/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Lb=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/allowlist`,headers:{},query:{},params:{botId:e.botId},body:{}});var _b=e=>({path:`/v1/admin/bots/${encodeURIComponent(e.botId)}/allowlist`,headers:{},query:{},params:{botId:e.botId},body:{setting:e.setting,users:e.users}});var Qb=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/migrate-to-v4`,headers:{},query:{},params:{id:e.id},body:{}});var Fb=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/billing/invoices`,headers:{},query:{},params:{id:e.id},body:{}});var Ob=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/billing/upcoming-invoice`,headers:{},query:{},params:{id:e.id},body:{}});var Nb=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/billing/invoices/charge-unpaid`,headers:{},query:{},params:{id:e.id},body:{invoiceIds:e.invoiceIds}});var $b=e=>({path:"/v1/admin/workspaces",headers:{},query:{},params:{},body:{name:e.name,billingVersion:e.billingVersion}});var Jb=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/public`,headers:{},query:{},params:{id:e.id},body:{}});var Yb=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Xb=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/usages`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var tf=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/usages/by-bot`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var sf=e=>({path:"/v1/admin/workspaces/usages/quota-completion",headers:{},query:{},params:{},body:{}});var af=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/quota`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var pf=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/quotas`,headers:{},query:{period:e.period},params:{id:e.id},body:{}});var cf=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{name:e.name,spendingLimit:e.spendingLimit,about:e.about,profilePicture:e.profilePicture,contactEmail:e.contactEmail,website:e.website,socialAccounts:e.socialAccounts,isPublic:e.isPublic,handle:e.handle}});var lf=e=>({path:"/v1/admin/workspaces/handle-availability",headers:{},query:{},params:{},body:{handle:e.handle}});var yf=e=>({path:"/v1/admin/workspaces",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,handle:e.handle},params:{},body:{}});var Rf=e=>({path:"/v1/admin/workspaces/public",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,workspaceIds:e.workspaceIds,search:e.search},params:{},body:{}});var hf=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var ff=e=>({path:`/v1/admin/workspaces/${encodeURIComponent(e.id)}/audit-records`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var xf=e=>({path:`/v1/admin/workspaces/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{value:e.value}});var Pf=e=>({path:`/v1/admin/workspaces/preferences/${encodeURIComponent(e.key)}`,headers:{},query:{},params:{key:e.key},body:{}});var Af=e=>({path:"/v1/admin/workspace-members",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{},body:{}});var Bf=e=>({path:"/v1/admin/workspace-members/me",headers:{},query:{},params:{},body:{}});var wf=e=>({path:`/v1/admin/workspace-members/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Gf=e=>({path:"/v1/admin/workspace-members",headers:{},query:{},params:{},body:{email:e.email,role:e.role,sendEmail:e.sendEmail}});var Ef=e=>({path:`/v1/admin/workspace-members/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{role:e.role}});var Wf=e=>({path:"/v1/admin/integrations/iaks",headers:{},query:{integrationId:e.integrationId},params:{},body:{}});var Hf=e=>({path:"/v1/admin/integrations/iaks",headers:{},query:{},params:{},body:{integrationId:e.integrationId,note:e.note}});var Df=e=>({path:`/v1/admin/integrations/iaks/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Mf=e=>({path:"/v1/admin/integrations",headers:{},query:{},params:{},body:{name:e.name,version:e.version,configuration:e.configuration,configurations:e.configurations,states:e.states,events:e.events,actions:e.actions,entities:e.entities,identifier:e.identifier,channels:e.channels,user:e.user,interfaces:e.interfaces,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,secrets:e.secrets,code:e.code,url:e.url,dev:e.dev,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,layers:e.layers,attributes:e.attributes}});var Vf=e=>({path:"/v1/admin/integrations/validate",headers:{},query:{},params:{},body:{name:e.name,version:e.version,configuration:e.configuration,configurations:e.configurations,states:e.states,events:e.events,actions:e.actions,entities:e.entities,identifier:e.identifier,channels:e.channels,user:e.user,interfaces:e.interfaces,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,secrets:e.secrets,code:e.code,url:e.url,dev:e.dev,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,layers:e.layers,attributes:e.attributes}});var Kf=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{configuration:e.configuration,configurations:e.configurations,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,channels:e.channels,maxExecutionTime:e.maxExecutionTime,identifier:e.identifier,actions:e.actions,events:e.events,states:e.states,user:e.user,entities:e.entities,interfaces:e.interfaces,attributes:e.attributes,secrets:e.secrets,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,url:e.url,public:e.public,visibility:e.visibility,layers:e.layers}});var zf=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}/signing-secrets/rotate`,headers:{},query:{},params:{id:e.id},body:{}});var jf=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}/validate`,headers:{},query:{},params:{id:e.id},body:{configuration:e.configuration,configurations:e.configurations,extraOperations:e.extraOperations,sdkVersion:e.sdkVersion,channels:e.channels,maxExecutionTime:e.maxExecutionTime,identifier:e.identifier,actions:e.actions,events:e.events,states:e.states,user:e.user,entities:e.entities,interfaces:e.interfaces,attributes:e.attributes,secrets:e.secrets,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,url:e.url,public:e.public,visibility:e.visibility,layers:e.layers}});var Zf=e=>({path:"/v1/admin/integrations",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,limit:e.limit,name:e.name,version:e.version,interfaceId:e.interfaceId,interfaceName:e.interfaceName,installedByBotId:e.installedByBotId,verificationStatus:e.verificationStatus,search:e.search,sortBy:e.sortBy,direction:e.direction,visibility:e.visibility,dev:e.dev},params:{},body:{}});var eI=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var rI=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}/logs`,headers:{},query:{timeStart:e.timeStart,timeEnd:e.timeEnd,level:e.level,userId:e.userId,conversationId:e.conversationId,messageContains:e.messageContains,nextToken:e.nextToken},params:{id:e.id},body:{}});var nI=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var oI=e=>({path:`/v1/admin/integrations/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var pI=e=>({path:"/v1/admin/integrations/request-verification",headers:{},query:{},params:{},body:{integrationId:e.integrationId}});var cI=e=>({path:"/v1/admin/interfaces",headers:{},query:{},params:{},body:{name:e.name,version:e.version,entities:e.entities,events:e.events,actions:e.actions,channels:e.channels,nameTemplate:e.nameTemplate,sdkVersion:e.sdkVersion,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,attributes:e.attributes}});var lI=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var yI=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var RI=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{entities:e.entities,events:e.events,actions:e.actions,channels:e.channels,nameTemplate:e.nameTemplate,sdkVersion:e.sdkVersion,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,attributes:e.attributes}});var hI=e=>({path:`/v1/admin/interfaces/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var fI=e=>({path:"/v1/admin/interfaces",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var xI=e=>({path:"/v1/admin/plugins",headers:{},query:{},params:{},body:{name:e.name,version:e.version,configuration:e.configuration,states:e.states,events:e.events,actions:e.actions,user:e.user,conversation:e.conversation,message:e.message,sdkVersion:e.sdkVersion,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,dependencies:e.dependencies,attributes:e.attributes}});var PI=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var AI=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}/dereferenced`,headers:{},query:{interfaces:e.interfaces},params:{id:e.id},body:{}});var BI=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.name)}/${encodeURIComponent(e.version)}`,headers:{},query:{},params:{name:e.name,version:e.version},body:{}});var wI=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{configuration:e.configuration,states:e.states,events:e.events,actions:e.actions,user:e.user,conversation:e.conversation,message:e.message,sdkVersion:e.sdkVersion,code:e.code,icon:e.icon,readme:e.readme,title:e.title,description:e.description,public:e.public,visibility:e.visibility,dependencies:e.dependencies,attributes:e.attributes}});var GI=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var EI=e=>({path:"/v1/admin/plugins",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,name:e.name,version:e.version},params:{},body:{}});var WI=e=>({path:`/v1/admin/plugins/${encodeURIComponent(e.id)}/code/${encodeURIComponent(e.platform)}`,headers:{},query:{},params:{id:e.id,platform:e.platform},body:{}});var HI=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}`,headers:{},query:{type:e.type,period:e.period},params:{id:e.id},body:{}});var DI=e=>({path:"/v1/admin/usages/multiple",headers:{},query:{types:e.types,ids:e.ids,period:e.period},params:{},body:{}});var MI=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}/history`,headers:{},query:{type:e.type},params:{id:e.id},body:{}});var VI=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}/activity`,headers:{},query:{type:e.type,timestampFrom:e.timestampFrom,timestampUntil:e.timestampUntil,nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var KI=e=>({path:`/v1/admin/usages/${encodeURIComponent(e.id)}/daily-activity`,headers:{},query:{type:e.type,dateFrom:e.dateFrom,dateUntil:e.dateUntil,nextToken:e.nextToken,pageSize:e.pageSize},params:{id:e.id},body:{}});var zI=e=>({path:"/v1/admin/quotas/ai-spend",headers:{},query:{},params:{},body:{monthlySpendingLimit:e.monthlySpendingLimit}});var jI=e=>({path:"/v1/admin/activities",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,taskId:e.taskId,botId:e.botId},params:{},body:{}});var ZI=e=>({path:"/v1/admin/introspect",headers:{},query:{},params:{},body:{botId:e.botId}});var ex=e=>({path:"/v1/files",headers:{},query:{},params:{},body:{key:e.key,tags:e.tags,size:e.size,index:e.index,indexing:e.indexing,accessPolicies:e.accessPolicies,contentType:e.contentType,expiresAt:e.expiresAt,publicContentImmediatelyAccessible:e.publicContentImmediatelyAccessible,metadata:e.metadata}});var rx=e=>({path:`/v1/files/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var nx=e=>({path:"/v1/files",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,sortField:e.sortField,sortDirection:e.sortDirection,tags:e.tags,ids:e.ids,indexed:e.indexed},params:{},body:{}});var ox=e=>({path:`/v1/files/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var px=e=>({path:`/v1/files/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{metadata:e.metadata,tags:e.tags,accessPolicies:e.accessPolicies,expiresAt:e.expiresAt}});var cx=e=>({path:`/v1/files/${encodeURIComponent(e.idOrKey)}/${encodeURIComponent(e.destinationKey)}`,headers:{"x-destination-bot-id":e["x-destination-bot-id"]},query:{},params:{idOrKey:e.idOrKey,destinationKey:e.destinationKey},body:{overwrite:e.overwrite}});var lx=e=>({path:"/v1/files/search",headers:{},query:{tags:e.tags,query:e.query,contextDepth:e.contextDepth,limit:e.limit,consolidate:e.consolidate,includeBreadcrumb:e.includeBreadcrumb,withContext:e.withContext},params:{},body:{}});var yx=e=>({path:`/v1/files/${encodeURIComponent(e.id)}/passages`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,limit:e.limit},params:{id:e.id},body:{}});var Rx=e=>({path:`/v1/files/${encodeURIComponent(e.id)}/passages`,headers:{},query:{},params:{id:e.id},body:{passages:e.passages}});var hx=e=>({path:"/v1/files/tags",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{},body:{}});var fx=e=>({path:`/v1/files/tags/${encodeURIComponent(e.tag)}/values`,headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize},params:{tag:e.tag},body:{}});var xx=e=>({path:"/v1/files/knowledge-bases",headers:{},query:{},params:{},body:{name:e.name,description:e.description,tags:e.tags}});var Px=e=>({path:`/v1/files/knowledge-bases/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{}});var Ax=e=>({path:`/v1/files/knowledge-bases/${encodeURIComponent(e.id)}`,headers:{},query:{},params:{id:e.id},body:{name:e.name,description:e.description,tags:e.tags}});var Bx=e=>({path:"/v1/files/knowledge-bases",headers:{},query:{nextToken:e.nextToken,pageSize:e.pageSize,tags:e.tags},params:{},body:{}});var wx=e=>({path:"/v1/tables",headers:{},query:{tags:e.tags},params:{},body:{}});var Gx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{}});var Ex=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{factor:e.factor,frozen:e.frozen,keyColumn:e.keyColumn,schema:e.schema,tags:e.tags,isComputeEnabled:e.isComputeEnabled}});var Wx=e=>({path:"/v1/tables",headers:{},query:{},params:{},body:{name:e.name,factor:e.factor,frozen:e.frozen,keyColumn:e.keyColumn,schema:e.schema,tags:e.tags,isComputeEnabled:e.isComputeEnabled}});var Hx=e=>({path:`/v1/tables/${encodeURIComponent(e.sourceTableId)}/duplicate`,headers:{},query:{},params:{sourceTableId:e.sourceTableId},body:{tableName:e.tableName,schemaOnly:e.schemaOnly,factor:e.factor}});var Dx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/export`,headers:{},query:{format:e.format,compress:e.compress},params:{table:e.table},body:{}});var Mx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/jobs`,headers:{},query:{},params:{table:e.table},body:{}});var Vx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/import`,headers:{},query:{},params:{table:e.table},body:{fileId:e.fileId}});var Kx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{name:e.name,frozen:e.frozen,keyColumn:e.keyColumn,schema:e.schema,tags:e.tags,isComputeEnabled:e.isComputeEnabled,factor:e.factor}});var zx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/column`,headers:{},query:{},params:{table:e.table},body:{name:e.name,newName:e.newName}});var jx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}`,headers:{},query:{},params:{table:e.table},body:{}});var Zx=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/row`,headers:{},query:{id:e.id},params:{table:e.table},body:{}});var ek=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows/find`,headers:{},query:{},params:{table:e.table},body:{limit:e.limit,offset:e.offset,filter:e.filter,group:e.group,search:e.search,select:e.select,orderBy:e.orderBy,orderDirection:e.orderDirection}});var rk=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows`,headers:{},query:{},params:{table:e.table},body:{rows:e.rows,waitComputed:e.waitComputed}});var nk=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows/delete`,headers:{},query:{},params:{table:e.table},body:{ids:e.ids,filter:e.filter,deleteAllRows:e.deleteAllRows}});var ok=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows`,headers:{},query:{},params:{table:e.table},body:{rows:e.rows,waitComputed:e.waitComputed}});var pk=e=>({path:`/v1/tables/${encodeURIComponent(e.table)}/rows/upsert`,headers:{},query:{},params:{table:e.table},body:{rows:e.rows,keyColumn:e.keyColumn,waitComputed:e.waitComputed}});var Gt=class{constructor(t,s={}){this.httpClient=t;this.props=s}createConversation=async t=>{let{path:s,headers:n,query:a,body:o}=iR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getConversation=async t=>{let{path:s,headers:n,query:a,body:o}=uR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listConversations=async t=>{let{path:s,headers:n,query:a,body:o}=dR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateConversation=async t=>{let{path:s,headers:n,query:a,body:o}=gR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateConversation=async t=>{let{path:s,headers:n,query:a,body:o}=mR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteConversation=async t=>{let{path:s,headers:n,query:a,body:o}=qR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listParticipants=async t=>{let{path:s,headers:n,query:a,body:o}=bR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};addParticipant=async t=>{let{path:s,headers:n,query:a,body:o}=IR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getParticipant=async t=>{let{path:s,headers:n,query:a,body:o}=kR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};removeParticipant=async t=>{let{path:s,headers:n,query:a,body:o}=vR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createEvent=async t=>{let{path:s,headers:n,query:a,body:o}=CR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getEvent=async t=>{let{path:s,headers:n,query:a,body:o}=TR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listEvents=async t=>{let{path:s,headers:n,query:a,body:o}=UR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};cancelScheduledEvent=async t=>{let{path:s,headers:n,query:a,body:o}=SR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createMessage=async t=>{let{path:s,headers:n,query:a,body:o}=LR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateMessage=async t=>{let{path:s,headers:n,query:a,body:o}=_R(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getMessage=async t=>{let{path:s,headers:n,query:a,body:o}=QR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateMessage=async t=>{let{path:s,headers:n,query:a,body:o}=FR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listMessages=async t=>{let{path:s,headers:n,query:a,body:o}=OR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteMessage=async t=>{let{path:s,headers:n,query:a,body:o}=NR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};initializeIncomingMessage=async t=>{let{path:s,headers:n,query:a,body:o}=$R(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};importMessages=async t=>{let{path:s,headers:n,query:a,body:o}=JR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createUser=async t=>{let{path:s,headers:n,query:a,body:o}=YR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getUser=async t=>{let{path:s,headers:n,query:a,body:o}=XR(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsers=async t=>{let{path:s,headers:n,query:a,body:o}=tq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateUser=async t=>{let{path:s,headers:n,query:a,body:o}=sq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateUser=async t=>{let{path:s,headers:n,query:a,body:o}=aq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteUser=async t=>{let{path:s,headers:n,query:a,body:o}=iq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setStateExpiry=async t=>{let{path:s,headers:n,query:a,body:o}=uq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getState=async t=>{let{path:s,headers:n,query:a,body:o}=dq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setState=async t=>{let{path:s,headers:n,query:a,body:o}=gq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrSetState=async t=>{let{path:s,headers:n,query:a,body:o}=mq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};patchState=async t=>{let{path:s,headers:n,query:a,body:o}=qq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"patch",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};callAction=async t=>{let{path:s,headers:n,query:a,body:o}=bq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};unlinkIntegrationIdentifier=async t=>{let{path:s,headers:n,query:a,body:o}=Iq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationIdentifierAvailability=async t=>{let{path:s,headers:n,query:a,body:o}=kq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationInstanceIdentifiers=async t=>{let{path:s,headers:n,query:a,body:o}=vq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};configureIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=Cq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=Tq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=Uq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=Sq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=Lq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkflows=async t=>{let{path:s,headers:n,query:a,body:o}=_q(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateWorkflow=async t=>{let{path:s,headers:n,query:a,body:o}=Qq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listTagValues=async t=>{let{path:s,headers:n,query:a,body:o}=Fq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};trackAnalytics=async t=>{let{path:s,headers:n,query:a,body:o}=Oq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};captureObservation=async t=>{let{path:s,headers:n,query:a,body:o}=Nq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};runVrl=async t=>{let{path:s,headers:n,query:a,body:o}=$q(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAccount=async t=>{let{path:s,headers:n,query:a,body:o}=Jq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateAccount=async t=>{let{path:s,headers:n,query:a,body:o}=Yq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteAccount=async t=>{let{path:s,headers:n,query:a,body:o}=Xq(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPersonalAccessTokens=async t=>{let{path:s,headers:n,query:a,body:o}=th(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createPersonalAccessToken=async t=>{let{path:s,headers:n,query:a,body:o}=sh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deletePersonalAccessToken=async t=>{let{path:s,headers:n,query:a,body:o}=ah(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setAccountPreference=async t=>{let{path:s,headers:n,query:a,body:o}=ih(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAccountPreference=async t=>{let{path:s,headers:n,query:a,body:o}=uh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicIntegrations=async t=>{let{path:s,headers:n,query:a,body:o}=dh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicIntegrationById=async t=>{let{path:s,headers:n,query:a,body:o}=gh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=mh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicPlugins=async t=>{let{path:s,headers:n,query:a,body:o}=qh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicPluginById=async t=>{let{path:s,headers:n,query:a,body:o}=bh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getDereferencedPublicPluginById=async t=>{let{path:s,headers:n,query:a,body:o}=Ih(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=kh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicPluginCode=async t=>{let{path:s,headers:n,query:a,body:o}=vh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicInterfaces=async t=>{let{path:s,headers:n,query:a,body:o}=Ch(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicInterfaceById=async t=>{let{path:s,headers:n,query:a,body:o}=Th(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicInterface=async t=>{let{path:s,headers:n,query:a,body:o}=Uh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createBot=async t=>{let{path:s,headers:n,query:a,body:o}=Sh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateBot=async t=>{let{path:s,headers:n,query:a,body:o}=Lh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};rotateBotSigningSecrets=async t=>{let{path:s,headers:n,query:a,body:o}=_h(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};transferBot=async t=>{let{path:s,headers:n,query:a,body:o}=Qh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBots=async t=>{let{path:s,headers:n,query:a,body:o}=Fh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBot=async t=>{let{path:s,headers:n,query:a,body:o}=Oh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteBot=async t=>{let{path:s,headers:n,query:a,body:o}=Nh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotLogs=async t=>{let{path:s,headers:n,query:a,body:o}=$h(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotWebchat=async t=>{let{path:s,headers:n,query:a,body:o}=Jh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotAnalytics=async t=>{let{path:s,headers:n,query:a,body:o}=Yh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listActionRuns=async t=>{let{path:s,headers:n,query:a,body:o}=Xh(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotIssue=async t=>{let{path:s,headers:n,query:a,body:o}=tb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotIssues=async t=>{let{path:s,headers:n,query:a,body:o}=sb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteBotIssue=async t=>{let{path:s,headers:n,query:a,body:o}=ab(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotIssueEvents=async t=>{let{path:s,headers:n,query:a,body:o}=ib(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotVersions=async t=>{let{path:s,headers:n,query:a,body:o}=ub(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotVersion=async t=>{let{path:s,headers:n,query:a,body:o}=db(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotJson=async t=>{let{path:s,headers:n,query:a,body:o}=gb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};publishFromBotJson=async t=>{let{path:s,headers:n,query:a,body:o}=mb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createBotVersion=async t=>{let{path:s,headers:n,query:a,body:o}=qb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deployBotVersion=async t=>{let{path:s,headers:n,query:a,body:o}=bb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createIntegrationShareableId=async t=>{let{path:s,headers:n,query:a,body:o}=Ib(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteIntegrationShareableId=async t=>{let{path:s,headers:n,query:a,body:o}=kb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationShareableId=async t=>{let{path:s,headers:n,query:a,body:o}=vb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};unlinkSandboxedConversations=async t=>{let{path:s,headers:n,query:a,body:o}=Cb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listBotApiKeys=async t=>{let{path:s,headers:n,query:a,body:o}=Tb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createBotApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=Ub(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteBotApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=Sb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getBotAllowlist=async t=>{let{path:s,headers:n,query:a,body:o}=Lb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateBotAllowlist=async t=>{let{path:s,headers:n,query:a,body:o}=_b(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};migrateWorkspaceToV4=async t=>{let{path:s,headers:n,query:a,body:o}=Qb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceInvoices=async t=>{let{path:s,headers:n,query:a,body:o}=Fb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getUpcomingInvoice=async t=>{let{path:s,headers:n,query:a,body:o}=Ob(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};chargeWorkspaceUnpaidInvoices=async t=>{let{path:s,headers:n,query:a,body:o}=Nb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=$b(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPublicWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=Jb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=Yb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceUsages=async t=>{let{path:s,headers:n,query:a,body:o}=Xb(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};breakDownWorkspaceUsageByBot=async t=>{let{path:s,headers:n,query:a,body:o}=tf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAllWorkspaceQuotaCompletion=async t=>{let{path:s,headers:n,query:a,body:o}=sf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspaceQuota=async t=>{let{path:s,headers:n,query:a,body:o}=af(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceQuotas=async t=>{let{path:s,headers:n,query:a,body:o}=pf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=cf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};checkHandleAvailability=async t=>{let{path:s,headers:n,query:a,body:o}=lf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaces=async t=>{let{path:s,headers:n,query:a,body:o}=yf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPublicWorkspaces=async t=>{let{path:s,headers:n,query:a,body:o}=Rf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteWorkspace=async t=>{let{path:s,headers:n,query:a,body:o}=hf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getAuditRecords=async t=>{let{path:s,headers:n,query:a,body:o}=ff(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setWorkspacePreference=async t=>{let{path:s,headers:n,query:a,body:o}=xf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspacePreference=async t=>{let{path:s,headers:n,query:a,body:o}=Pf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listWorkspaceMembers=async t=>{let{path:s,headers:n,query:a,body:o}=Af(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=Bf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=wf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=Gf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateWorkspaceMember=async t=>{let{path:s,headers:n,query:a,body:o}=Ef(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listIntegrationApiKeys=async t=>{let{path:s,headers:n,query:a,body:o}=Wf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createIntegrationApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=Hf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteIntegrationApiKey=async t=>{let{path:s,headers:n,query:a,body:o}=Df(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=Mf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};validateIntegrationCreation=async t=>{let{path:s,headers:n,query:a,body:o}=Vf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=Kf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};rotateIntegrationSigningSecrets=async t=>{let{path:s,headers:n,query:a,body:o}=zf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};validateIntegrationUpdate=async t=>{let{path:s,headers:n,query:a,body:o}=jf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listIntegrations=async t=>{let{path:s,headers:n,query:a,body:o}=Zf(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=eI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationLogs=async t=>{let{path:s,headers:n,query:a,body:o}=rI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getIntegrationByName=async t=>{let{path:s,headers:n,query:a,body:o}=nI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteIntegration=async t=>{let{path:s,headers:n,query:a,body:o}=oI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};requestIntegrationVerification=async t=>{let{path:s,headers:n,query:a,body:o}=pI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createInterface=async t=>{let{path:s,headers:n,query:a,body:o}=cI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getInterface=async t=>{let{path:s,headers:n,query:a,body:o}=lI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getInterfaceByName=async t=>{let{path:s,headers:n,query:a,body:o}=yI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateInterface=async t=>{let{path:s,headers:n,query:a,body:o}=RI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteInterface=async t=>{let{path:s,headers:n,query:a,body:o}=hI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listInterfaces=async t=>{let{path:s,headers:n,query:a,body:o}=fI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=xI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=PI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getDereferencedPlugin=async t=>{let{path:s,headers:n,query:a,body:o}=AI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPluginByName=async t=>{let{path:s,headers:n,query:a,body:o}=BI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updatePlugin=async t=>{let{path:s,headers:n,query:a,body:o}=wI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deletePlugin=async t=>{let{path:s,headers:n,query:a,body:o}=GI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listPlugins=async t=>{let{path:s,headers:n,query:a,body:o}=EI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getPluginCode=async t=>{let{path:s,headers:n,query:a,body:o}=WI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getUsage=async t=>{let{path:s,headers:n,query:a,body:o}=HI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getMultipleUsages=async t=>{let{path:s,headers:n,query:a,body:o}=DI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsageHistory=async t=>{let{path:s,headers:n,query:a,body:o}=MI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsageActivity=async t=>{let{path:s,headers:n,query:a,body:o}=VI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listUsageActivityDaily=async t=>{let{path:s,headers:n,query:a,body:o}=KI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};changeAISpendQuota=async t=>{let{path:s,headers:n,query:a,body:o}=zI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listActivities=async t=>{let{path:s,headers:n,query:a,body:o}=jI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};introspect=async t=>{let{path:s,headers:n,query:a,body:o}=ZI(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};upsertFile=async t=>{let{path:s,headers:n,query:a,body:o}=ex(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteFile=async t=>{let{path:s,headers:n,query:a,body:o}=rx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFiles=async t=>{let{path:s,headers:n,query:a,body:o}=nx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getFile=async t=>{let{path:s,headers:n,query:a,body:o}=ox(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateFileMetadata=async t=>{let{path:s,headers:n,query:a,body:o}=px(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};copyFile=async t=>{let{path:s,headers:n,query:a,body:o}=cx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};searchFiles=async t=>{let{path:s,headers:n,query:a,body:o}=lx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFilePassages=async t=>{let{path:s,headers:n,query:a,body:o}=yx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};setFilePassages=async t=>{let{path:s,headers:n,query:a,body:o}=Rx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFileTags=async t=>{let{path:s,headers:n,query:a,body:o}=hx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listFileTagValues=async t=>{let{path:s,headers:n,query:a,body:o}=fx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createKnowledgeBase=async t=>{let{path:s,headers:n,query:a,body:o}=xx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteKnowledgeBase=async t=>{let{path:s,headers:n,query:a,body:o}=Px(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateKnowledgeBase=async t=>{let{path:s,headers:n,query:a,body:o}=Ax(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listKnowledgeBases=async t=>{let{path:s,headers:n,query:a,body:o}=Bx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};listTables=async t=>{let{path:s,headers:n,query:a,body:o}=wx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getTable=async t=>{let{path:s,headers:n,query:a,body:o}=Gx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getOrCreateTable=async t=>{let{path:s,headers:n,query:a,body:o}=Ex(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createTable=async t=>{let{path:s,headers:n,query:a,body:o}=Wx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};duplicateTable=async t=>{let{path:s,headers:n,query:a,body:o}=Hx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};exportTable=async t=>{let{path:s,headers:n,query:a,body:o}=Dx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getTableJobs=async t=>{let{path:s,headers:n,query:a,body:o}=Mx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};importTable=async t=>{let{path:s,headers:n,query:a,body:o}=Vx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateTable=async t=>{let{path:s,headers:n,query:a,body:o}=Kx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};renameTableColumn=async t=>{let{path:s,headers:n,query:a,body:o}=zx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteTable=async t=>{let{path:s,headers:n,query:a,body:o}=jx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"delete",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};getTableRow=async t=>{let{path:s,headers:n,query:a,body:o}=Zx(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"get",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};findTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=ek(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};createTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=rk(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};deleteTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=nk(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};updateTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=ok(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"put",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})};upsertTableRows=async t=>{let{path:s,headers:n,query:a,body:o}=pk(t),i=this.props.toRequest??c,p=this.props.toApiError??d,u=i({method:"post",path:s,headers:{...n},query:{...a},body:o});return this.httpClient.request(u).then(r=>r.data).catch(r=>{throw p(r)})}};function d(e){let t=e?.response?.data;return t?we(t):we(e)}var ck=class extends Gt{config;constructor(t={}){let s=$.getClientConfig(t),n=W.createHttpClient(s);super(n,{toApiError:z.toApiError}),t.retry&&(n.retry=t.retry),this.config=s}get list(){return{conversations:t=>new R.AsyncCollection(({nextToken:s})=>this.listConversations({nextToken:s,...t}).then(n=>({...n,items:n.conversations}))),participants:t=>new R.AsyncCollection(({nextToken:s})=>this.listParticipants({nextToken:s,...t}).then(n=>({...n,items:n.participants}))),events:t=>new R.AsyncCollection(({nextToken:s})=>this.listEvents({nextToken:s,...t}).then(n=>({...n,items:n.events}))),messages:t=>new R.AsyncCollection(({nextToken:s})=>this.listMessages({nextToken:s,...t}).then(n=>({...n,items:n.messages}))),users:t=>new R.AsyncCollection(({nextToken:s})=>this.listUsers({nextToken:s,...t}).then(n=>({...n,items:n.users}))),publicIntegrations:t=>new R.AsyncCollection(({nextToken:s})=>this.listPublicIntegrations({nextToken:s,...t}).then(n=>({...n,items:n.integrations}))),bots:t=>new R.AsyncCollection(({nextToken:s})=>this.listBots({nextToken:s,...t}).then(n=>({...n,items:n.bots}))),botIssues:t=>new R.AsyncCollection(({nextToken:s})=>this.listBotIssues({nextToken:s,...t}).then(n=>({...n,items:n.issues}))),workspaces:t=>new R.AsyncCollection(({nextToken:s})=>this.listWorkspaces({nextToken:s,...t}).then(n=>({...n,items:n.workspaces}))),publicWorkspaces:t=>new R.AsyncCollection(({nextToken:s})=>this.listPublicWorkspaces({nextToken:s,...t}).then(n=>({...n,items:n.workspaces}))),workspaceMembers:t=>new R.AsyncCollection(({nextToken:s})=>this.listWorkspaceMembers({nextToken:s,...t}).then(n=>({...n,items:n.members}))),integrations:t=>new R.AsyncCollection(({nextToken:s})=>this.listIntegrations({nextToken:s,...t}).then(n=>({...n,items:n.integrations}))),interfaces:t=>new R.AsyncCollection(({nextToken:s})=>this.listInterfaces({nextToken:s,...t}).then(n=>({...n,items:n.interfaces}))),publicInterfaces:t=>new R.AsyncCollection(({nextToken:s})=>this.listPublicInterfaces({nextToken:s,...t}).then(n=>({...n,items:n.interfaces}))),plugins:t=>new R.AsyncCollection(({nextToken:s})=>this.listPlugins({nextToken:s,...t}).then(n=>({...n,items:n.plugins}))),publicPlugins:t=>new R.AsyncCollection(({nextToken:s})=>this.listPublicPlugins({nextToken:s,...t}).then(n=>({...n,items:n.plugins}))),activities:t=>new R.AsyncCollection(({nextToken:s})=>this.listActivities({nextToken:s,...t}).then(n=>({...n,items:n.activities}))),files:t=>new R.AsyncCollection(({nextToken:s})=>this.listFiles({nextToken:s,...t}).then(n=>({...n,items:n.files}))),filePassages:t=>new R.AsyncCollection(({nextToken:s})=>this.listFilePassages({nextToken:s,...t}).then(n=>({...n,items:n.passages}))),fileTags:t=>new R.AsyncCollection(({nextToken:s})=>this.listFileTags({nextToken:s,...t}).then(n=>({...n,items:n.tags}))),fileTagValues:t=>new R.AsyncCollection(({nextToken:s})=>this.listFileTagValues({nextToken:s,...t}).then(n=>({...n,items:n.values}))),knowledgeBases:t=>new R.AsyncCollection(({nextToken:s})=>this.listKnowledgeBases({nextToken:s,...t}).then(n=>({...n,items:n.knowledgeBases}))),usageActivity:t=>new R.AsyncCollection(({nextToken:s})=>this.listUsageActivity({nextToken:s,...t}).then(n=>({...n,items:n.data}))),usageActivityDaily:t=>new R.AsyncCollection(({nextToken:s})=>this.listUsageActivityDaily({nextToken:s,...t}).then(n=>({...n,items:n.data}))),workflows:t=>new R.AsyncCollection(({nextToken:s})=>this.listWorkflows({nextToken:s,...t}).then(n=>({...n,items:n.workflows})))}}uploadFile=async t=>await wt(this,t)};export{er as AlreadyExistsError,ar as BreakingChangesError,ck as Client,Ht as ForbiddenError,Wt as InternalError,Nt as InvalidDataFormatError,Kt as InvalidIdentifierError,Vt as InvalidJsonSchemaError,Dt as InvalidPayloadError,Zt as InvalidQueryError,nr as LimitExceededError,Mt as MethodNotFoundError,or as OperationTimeoutError,Qt as PayloadTooLargeError,rr as PaymentRequiredError,sr as QuotaExceededError,tr as RateLimitedError,zt as ReferenceConstraintError,Yt as ReferenceNotFoundError,$t as RelationConflictError,jt as ResourceGoneError,Jt as ResourceLockedConflictError,Ot as ResourceNotFoundError,Xt as RuntimeError,_t as UnauthorizedError,ye as UnknownError,Ft as UnsupportedMediaTypeError,ie as UploadFileError,Hg as admin,Vy as billing,we as errorFrom,km as files,W as http,Nk as isApiError,wu as runtime,aR as tables};
7
7
  //# sourceMappingURL=index.mjs.map