@jibb-open/jssdk 3.5.9 → 3.5.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -2
- package/{dist/api → api}/admin.js +0 -0
- package/{dist/api → api}/auth.js +0 -0
- package/{dist/api → api}/eventbus.js +0 -0
- package/{dist/api → api}/index.js +0 -0
- package/{dist/api → api}/meeting.js +0 -0
- package/{dist/api → api}/recording.js +0 -0
- package/{dist/api → api}/superadmin.js +0 -0
- package/{dist/api → api}/user.js +0 -0
- package/{dist/api → api}/webexbot.js +0 -0
- package/{dist/api → api}/whiteboard.js +0 -0
- package/{dist/config.js → config.js} +0 -0
- package/{dist/examples → examples}/browser/462.jibb.js +0 -0
- package/{dist/examples → examples}/browser/index.html +0 -0
- package/{dist/examples → examples}/browser/jibb.js +0 -0
- package/{dist/examples → examples}/browser/startSession.js +0 -0
- package/{dist/examples → examples}/examples.js +0 -0
- package/{dist/examples → examples}/webexDevicesMacros/cameraPresets/jibb.js +2 -3
- package/{dist/examples/webexDevicesMacros/webexDevice JSSDK → examples/webexDevicesMacros/jssdk}/jibb_WebexXapi.js +0 -0
- package/{dist/examples → examples}/webexDevicesMacros/simplestExample/jibb.js +2 -3
- package/{dist/examples → examples}/webexDevicesMacros/withCameraControl/jibb.js +2 -3
- package/package.json +1 -1
- package/{dist/post-processing.js → post-processing.js} +0 -0
- package/{dist/types → types}/exceptions.js +0 -0
- package/{dist/types → types}/jibb.pb.js +0 -0
- package/{dist/types → types}/proto.js +0 -0
- package/{dist/types → types}/types.js +0 -0
- package/{dist/utils → utils}/cached_variable.js +0 -0
- package/{dist/utils → utils}/future.js +0 -0
- package/{dist/utils → utils}/http/http.axios.js +0 -0
- package/{dist/utils → utils}/http/index.js +0 -0
- package/{dist/utils → utils}/index.js +0 -0
- package/{dist/utils → utils}/logger/index.js +0 -0
- package/{dist/utils → utils}/logger/logger.empty.js +0 -0
- package/{dist/utils → utils}/logger/logger.pino.js +0 -0
- package/{dist/ws → ws}/connection_base.js +0 -0
- package/{dist/ws → ws}/eventbus.js +0 -0
- package/{dist/ws → ws}/index.js +0 -0
- package/{dist/ws → ws}/ipsa.js +0 -0
- package/{dist/ws → ws}/meeting.js +0 -0
- package/{dist/ws → ws}/observable_connection.js +0 -0
- package/{dist/ws → ws}/retry_connection.js +0 -0
- package/.babelrc +0 -31
- package/dist/package.json +0 -69
- package/src/api/admin.js +0 -333
- package/src/api/auth.js +0 -208
- package/src/api/eventbus.js +0 -246
- package/src/api/index.js +0 -26
- package/src/api/meeting.js +0 -421
- package/src/api/recording.js +0 -225
- package/src/api/superadmin.js +0 -84
- package/src/api/user.js +0 -46
- package/src/api/webexbot.js +0 -32
- package/src/api/whiteboard.js +0 -175
- package/src/config.js +0 -12
- package/src/examples/browser/462.jibb.js +0 -1
- package/src/examples/browser/index.html +0 -17
- package/src/examples/browser/jibb.js +0 -2
- package/src/examples/browser/startSession.js +0 -112
- package/src/examples/examples.js +0 -5
- package/src/examples/webexDevicesMacros/cameraPresets/jibb.js +0 -338
- package/src/examples/webexDevicesMacros/simplestExample/jibb.js +0 -212
- package/src/examples/webexDevicesMacros/webexDevice JSSDK/jibb_WebexXapi.js +0 -2
- package/src/examples/webexDevicesMacros/withCameraControl/jibb.js +0 -303
- package/src/index.webex-devices.js +0 -13
- package/src/post-processing.js +0 -39
- package/src/types/exceptions.js +0 -48
- package/src/types/jibb.pb.js +0 -1357
- package/src/types/proto.js +0 -7
- package/src/types/types.js +0 -64
- package/src/utils/cached_variable.js +0 -23
- package/src/utils/future.js +0 -24
- package/src/utils/http/http.axios.js +0 -34
- package/src/utils/http/http.xapi.js +0 -87
- package/src/utils/http/index.js +0 -8
- package/src/utils/index.js +0 -5
- package/src/utils/logger/index.js +0 -11
- package/src/utils/logger/logger.empty.js +0 -25
- package/src/utils/logger/logger.pino.js +0 -15
- package/src/ws/connection_base.js +0 -81
- package/src/ws/eventbus.js +0 -363
- package/src/ws/index.js +0 -15
- package/src/ws/ipsa.js +0 -246
- package/src/ws/meeting.js +0 -170
- package/src/ws/observable_connection.js +0 -84
- package/src/ws/retry_connection.js +0 -82
- package/webpack.config.cjs +0 -144
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
/*! For license information please see jibb.js.LICENSE.txt */
|
|
2
|
-
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.JIBB=e():t.JIBB=e()}(globalThis,(()=>(()=>{var t,e,r={806:(t,e,r)=>{t.exports=r(642)},107:(t,e,r)=>{"use strict";var n=r(320),o=r(135),i=r(448),a=r(610),c=r(28),u=r(77),s=r(734),p=r(226),f=r(285),l=r(7);t.exports=function(t){return new Promise((function(e,r){var h,d=t.data,y=t.headers,v=t.responseType;function g(){t.cancelToken&&t.cancelToken.unsubscribe(h),t.signal&&t.signal.removeEventListener("abort",h)}n.isFormData(d)&&delete y["Content-Type"];var m=new XMLHttpRequest;if(t.auth){var w=t.auth.username||"",b=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";y.Authorization="Basic "+btoa(w+":"+b)}var x=c(t.baseURL,t.url);function j(){if(m){var n="getAllResponseHeaders"in m?u(m.getAllResponseHeaders()):null,i={data:v&&"text"!==v&&"json"!==v?m.response:m.responseText,status:m.status,statusText:m.statusText,headers:n,config:t,request:m};o((function(t){e(t),g()}),(function(t){r(t),g()}),i),m=null}}if(m.open(t.method.toUpperCase(),a(x,t.params,t.paramsSerializer),!0),m.timeout=t.timeout,"onloadend"in m?m.onloadend=j:m.onreadystatechange=function(){m&&4===m.readyState&&(0!==m.status||m.responseURL&&0===m.responseURL.indexOf("file:"))&&setTimeout(j)},m.onabort=function(){m&&(r(p("Request aborted",t,"ECONNABORTED",m)),m=null)},m.onerror=function(){r(p("Network Error",t,null,m)),m=null},m.ontimeout=function(){var e=t.timeout?"timeout of "+t.timeout+"ms exceeded":"timeout exceeded",n=t.transitional||f.transitional;t.timeoutErrorMessage&&(e=t.timeoutErrorMessage),r(p(e,t,n.clarifyTimeoutError?"ETIMEDOUT":"ECONNABORTED",m)),m=null},n.isStandardBrowserEnv()){var L=(t.withCredentials||s(x))&&t.xsrfCookieName?i.read(t.xsrfCookieName):void 0;L&&(y[t.xsrfHeaderName]=L)}"setRequestHeader"in m&&n.forEach(y,(function(t,e){void 0===d&&"content-type"===e.toLowerCase()?delete y[e]:m.setRequestHeader(e,t)})),n.isUndefined(t.withCredentials)||(m.withCredentials=!!t.withCredentials),v&&"json"!==v&&(m.responseType=t.responseType),"function"==typeof t.onDownloadProgress&&m.addEventListener("progress",t.onDownloadProgress),"function"==typeof t.onUploadProgress&&m.upload&&m.upload.addEventListener("progress",t.onUploadProgress),(t.cancelToken||t.signal)&&(h=function(t){m&&(r(!t||t&&t.type?new l("canceled"):t),m.abort(),m=null)},t.cancelToken&&t.cancelToken.subscribe(h),t.signal&&(t.signal.aborted?h():t.signal.addEventListener("abort",h))),d||(d=null),m.send(d)}))}},642:(t,e,r)=>{"use strict";var n=r(320),o=r(692),i=r(108),a=r(163),c=function t(e){var r=new i(e),c=o(i.prototype.request,r);return n.extend(c,i.prototype,r),n.extend(c,r),c.create=function(r){return t(a(e,r))},c}(r(285));c.Axios=i,c.Cancel=r(7),c.CancelToken=r(476),c.isCancel=r(874),c.VERSION=r(37).version,c.all=function(t){return Promise.all(t)},c.spread=r(166),c.isAxiosError=r(99),t.exports=c,t.exports.default=c},7:t=>{"use strict";function e(t){this.message=t}e.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},e.prototype.__CANCEL__=!0,t.exports=e},476:(t,e,r)=>{"use strict";var n=r(7);function o(t){if("function"!=typeof t)throw new TypeError("executor must be a function.");var e;this.promise=new Promise((function(t){e=t}));var r=this;this.promise.then((function(t){if(r._listeners){var e,n=r._listeners.length;for(e=0;e<n;e++)r._listeners[e](t);r._listeners=null}})),this.promise.then=function(t){var e,n=new Promise((function(t){r.subscribe(t),e=t})).then(t);return n.cancel=function(){r.unsubscribe(e)},n},t((function(t){r.reason||(r.reason=new n(t),e(r.reason))}))}o.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},o.prototype.subscribe=function(t){this.reason?t(this.reason):this._listeners?this._listeners.push(t):this._listeners=[t]},o.prototype.unsubscribe=function(t){if(this._listeners){var e=this._listeners.indexOf(t);-1!==e&&this._listeners.splice(e,1)}},o.source=function(){var t;return{token:new o((function(e){t=e})),cancel:t}},t.exports=o},874:t=>{"use strict";t.exports=function(t){return!(!t||!t.__CANCEL__)}},108:(t,e,r)=>{"use strict";var n=r(320),o=r(610),i=r(60),a=r(756),c=r(163),u=r(375),s=u.validators;function p(t){this.defaults=t,this.interceptors={request:new i,response:new i}}p.prototype.request=function(t){"string"==typeof t?(t=arguments[1]||{}).url=arguments[0]:t=t||{},(t=c(this.defaults,t)).method?t.method=t.method.toLowerCase():this.defaults.method?t.method=this.defaults.method.toLowerCase():t.method="get";var e=t.transitional;void 0!==e&&u.assertOptions(e,{silentJSONParsing:s.transitional(s.boolean),forcedJSONParsing:s.transitional(s.boolean),clarifyTimeoutError:s.transitional(s.boolean)},!1);var r=[],n=!0;this.interceptors.request.forEach((function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(n=n&&e.synchronous,r.unshift(e.fulfilled,e.rejected))}));var o,i=[];if(this.interceptors.response.forEach((function(t){i.push(t.fulfilled,t.rejected)})),!n){var p=[a,void 0];for(Array.prototype.unshift.apply(p,r),p=p.concat(i),o=Promise.resolve(t);p.length;)o=o.then(p.shift(),p.shift());return o}for(var f=t;r.length;){var l=r.shift(),h=r.shift();try{f=l(f)}catch(t){h(t);break}}try{o=a(f)}catch(t){return Promise.reject(t)}for(;i.length;)o=o.then(i.shift(),i.shift());return o},p.prototype.getUri=function(t){return t=c(this.defaults,t),o(t.url,t.params,t.paramsSerializer).replace(/^\?/,"")},n.forEach(["delete","get","head","options"],(function(t){p.prototype[t]=function(e,r){return this.request(c(r||{},{method:t,url:e,data:(r||{}).data}))}})),n.forEach(["post","put","patch"],(function(t){p.prototype[t]=function(e,r,n){return this.request(c(n||{},{method:t,url:e,data:r}))}})),t.exports=p},60:(t,e,r)=>{"use strict";var n=r(320);function o(){this.handlers=[]}o.prototype.use=function(t,e,r){return this.handlers.push({fulfilled:t,rejected:e,synchronous:!!r&&r.synchronous,runWhen:r?r.runWhen:null}),this.handlers.length-1},o.prototype.eject=function(t){this.handlers[t]&&(this.handlers[t]=null)},o.prototype.forEach=function(t){n.forEach(this.handlers,(function(e){null!==e&&t(e)}))},t.exports=o},28:(t,e,r)=>{"use strict";var n=r(900),o=r(787);t.exports=function(t,e){return t&&!n(e)?o(t,e):e}},226:(t,e,r)=>{"use strict";var n=r(669);t.exports=function(t,e,r,o,i){var a=new Error(t);return n(a,e,r,o,i)}},756:(t,e,r)=>{"use strict";var n=r(320),o=r(725),i=r(874),a=r(285),c=r(7);function u(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new c("canceled")}t.exports=function(t){return u(t),t.headers=t.headers||{},t.data=o.call(t,t.data,t.headers,t.transformRequest),t.headers=n.merge(t.headers.common||{},t.headers[t.method]||{},t.headers),n.forEach(["delete","get","head","post","put","patch","common"],(function(e){delete t.headers[e]})),(t.adapter||a.adapter)(t).then((function(e){return u(t),e.data=o.call(t,e.data,e.headers,t.transformResponse),e}),(function(e){return i(e)||(u(t),e&&e.response&&(e.response.data=o.call(t,e.response.data,e.response.headers,t.transformResponse))),Promise.reject(e)}))}},669:t=>{"use strict";t.exports=function(t,e,r,n,o){return t.config=e,r&&(t.code=r),t.request=n,t.response=o,t.isAxiosError=!0,t.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}},t}},163:(t,e,r)=>{"use strict";var n=r(320);t.exports=function(t,e){e=e||{};var r={};function o(t,e){return n.isPlainObject(t)&&n.isPlainObject(e)?n.merge(t,e):n.isPlainObject(e)?n.merge({},e):n.isArray(e)?e.slice():e}function i(r){return n.isUndefined(e[r])?n.isUndefined(t[r])?void 0:o(void 0,t[r]):o(t[r],e[r])}function a(t){if(!n.isUndefined(e[t]))return o(void 0,e[t])}function c(r){return n.isUndefined(e[r])?n.isUndefined(t[r])?void 0:o(void 0,t[r]):o(void 0,e[r])}function u(r){return r in e?o(t[r],e[r]):r in t?o(void 0,t[r]):void 0}var s={url:a,method:a,data:a,baseURL:c,transformRequest:c,transformResponse:c,paramsSerializer:c,timeout:c,timeoutMessage:c,withCredentials:c,adapter:c,responseType:c,xsrfCookieName:c,xsrfHeaderName:c,onUploadProgress:c,onDownloadProgress:c,decompress:c,maxContentLength:c,maxBodyLength:c,transport:c,httpAgent:c,httpsAgent:c,cancelToken:c,socketPath:c,responseEncoding:c,validateStatus:u};return n.forEach(Object.keys(t).concat(Object.keys(e)),(function(t){var e=s[t]||i,o=e(t);n.isUndefined(o)&&e!==u||(r[t]=o)})),r}},135:(t,e,r)=>{"use strict";var n=r(226);t.exports=function(t,e,r){var o=r.config.validateStatus;r.status&&o&&!o(r.status)?e(n("Request failed with status code "+r.status,r.config,null,r.request,r)):t(r)}},725:(t,e,r)=>{"use strict";var n=r(320),o=r(285);t.exports=function(t,e,r){var i=this||o;return n.forEach(r,(function(r){t=r.call(i,t,e)})),t}},285:(t,e,r)=>{"use strict";var n=r(320),o=r(554),i=r(669),a={"Content-Type":"application/x-www-form-urlencoded"};function c(t,e){!n.isUndefined(t)&&n.isUndefined(t["Content-Type"])&&(t["Content-Type"]=e)}var u,s={transitional:{silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},adapter:(("undefined"!=typeof XMLHttpRequest||"undefined"!=typeof process&&"[object process]"===Object.prototype.toString.call(process))&&(u=r(107)),u),transformRequest:[function(t,e){return o(e,"Accept"),o(e,"Content-Type"),n.isFormData(t)||n.isArrayBuffer(t)||n.isBuffer(t)||n.isStream(t)||n.isFile(t)||n.isBlob(t)?t:n.isArrayBufferView(t)?t.buffer:n.isURLSearchParams(t)?(c(e,"application/x-www-form-urlencoded;charset=utf-8"),t.toString()):n.isObject(t)||e&&"application/json"===e["Content-Type"]?(c(e,"application/json"),function(t,e,r){if(n.isString(t))try{return(0,JSON.parse)(t),n.trim(t)}catch(t){if("SyntaxError"!==t.name)throw t}return(0,JSON.stringify)(t)}(t)):t}],transformResponse:[function(t){var e=this.transitional||s.transitional,r=e&&e.silentJSONParsing,o=e&&e.forcedJSONParsing,a=!r&&"json"===this.responseType;if(a||o&&n.isString(t)&&t.length)try{return JSON.parse(t)}catch(t){if(a){if("SyntaxError"===t.name)throw i(t,this,"E_JSON_PARSE");throw t}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};n.forEach(["delete","get","head"],(function(t){s.headers[t]={}})),n.forEach(["post","put","patch"],(function(t){s.headers[t]=n.merge(a)})),t.exports=s},37:t=>{t.exports={version:"0.24.0"}},692:t=>{"use strict";t.exports=function(t,e){return function(){for(var r=new Array(arguments.length),n=0;n<r.length;n++)r[n]=arguments[n];return t.apply(e,r)}}},610:(t,e,r)=>{"use strict";var n=r(320);function o(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}t.exports=function(t,e,r){if(!e)return t;var i;if(r)i=r(e);else if(n.isURLSearchParams(e))i=e.toString();else{var a=[];n.forEach(e,(function(t,e){null!=t&&(n.isArray(t)?e+="[]":t=[t],n.forEach(t,(function(t){n.isDate(t)?t=t.toISOString():n.isObject(t)&&(t=JSON.stringify(t)),a.push(o(e)+"="+o(t))})))})),i=a.join("&")}if(i){var c=t.indexOf("#");-1!==c&&(t=t.slice(0,c)),t+=(-1===t.indexOf("?")?"?":"&")+i}return t}},787:t=>{"use strict";t.exports=function(t,e){return e?t.replace(/\/+$/,"")+"/"+e.replace(/^\/+/,""):t}},448:(t,e,r)=>{"use strict";var n=r(320);t.exports=n.isStandardBrowserEnv()?{write:function(t,e,r,o,i,a){var c=[];c.push(t+"="+encodeURIComponent(e)),n.isNumber(r)&&c.push("expires="+new Date(r).toGMTString()),n.isString(o)&&c.push("path="+o),n.isString(i)&&c.push("domain="+i),!0===a&&c.push("secure"),document.cookie=c.join("; ")},read:function(t){var e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove:function(t){this.write(t,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}}},900:t=>{"use strict";t.exports=function(t){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(t)}},99:t=>{"use strict";function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},e(t)}t.exports=function(t){return"object"===e(t)&&!0===t.isAxiosError}},734:(t,e,r)=>{"use strict";var n=r(320);t.exports=n.isStandardBrowserEnv()?function(){var t,e=/(msie|trident)/i.test(navigator.userAgent),r=document.createElement("a");function o(t){var n=t;return e&&(r.setAttribute("href",n),n=r.href),r.setAttribute("href",n),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:"/"===r.pathname.charAt(0)?r.pathname:"/"+r.pathname}}return t=o(window.location.href),function(e){var r=n.isString(e)?o(e):e;return r.protocol===t.protocol&&r.host===t.host}}():function(){return!0}},554:(t,e,r)=>{"use strict";var n=r(320);t.exports=function(t,e){n.forEach(t,(function(r,n){n!==e&&n.toUpperCase()===e.toUpperCase()&&(t[e]=r,delete t[n])}))}},77:(t,e,r)=>{"use strict";var n=r(320),o=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];t.exports=function(t){var e,r,i,a={};return t?(n.forEach(t.split("\n"),(function(t){if(i=t.indexOf(":"),e=n.trim(t.substr(0,i)).toLowerCase(),r=n.trim(t.substr(i+1)),e){if(a[e]&&o.indexOf(e)>=0)return;a[e]="set-cookie"===e?(a[e]?a[e]:[]).concat([r]):a[e]?a[e]+", "+r:r}})),a):a}},166:t=>{"use strict";t.exports=function(t){return function(e){return t.apply(null,e)}}},375:(t,e,r)=>{"use strict";function n(t){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},n(t)}var o=r(37).version,i={};["object","boolean","number","function","string","symbol"].forEach((function(t,e){i[t]=function(r){return n(r)===t||"a"+(e<1?"n ":" ")+t}}));var a={};i.transitional=function(t,e,r){function n(t,e){return"[Axios v"+o+"] Transitional option '"+t+"'"+e+(r?". "+r:"")}return function(r,o,i){if(!1===t)throw new Error(n(o," has been removed"+(e?" in "+e:"")));return e&&!a[o]&&(a[o]=!0,console.warn(n(o," has been deprecated since v"+e+" and will be removed in the near future"))),!t||t(r,o,i)}},t.exports={assertOptions:function(t,e,r){if("object"!==n(t))throw new TypeError("options must be an object");for(var o=Object.keys(t),i=o.length;i-- >0;){var a=o[i],c=e[a];if(c){var u=t[a],s=void 0===u||c(u,a,t);if(!0!==s)throw new TypeError("option "+a+" must be "+s)}else if(!0!==r)throw Error("Unknown option "+a)}},validators:i}},320:(t,e,r)=>{"use strict";function n(t){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},n(t)}var o=r(692),i=Object.prototype.toString;function a(t){return"[object Array]"===i.call(t)}function c(t){return void 0===t}function u(t){return null!==t&&"object"===n(t)}function s(t){if("[object Object]"!==i.call(t))return!1;var e=Object.getPrototypeOf(t);return null===e||e===Object.prototype}function p(t){return"[object Function]"===i.call(t)}function f(t,e){if(null!=t)if("object"!==n(t)&&(t=[t]),a(t))for(var r=0,o=t.length;r<o;r++)e.call(null,t[r],r,t);else for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&e.call(null,t[i],i,t)}t.exports={isArray:a,isArrayBuffer:function(t){return"[object ArrayBuffer]"===i.call(t)},isBuffer:function(t){return null!==t&&!c(t)&&null!==t.constructor&&!c(t.constructor)&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t)},isFormData:function(t){return"undefined"!=typeof FormData&&t instanceof FormData},isArrayBufferView:function(t){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(t):t&&t.buffer&&t.buffer instanceof ArrayBuffer},isString:function(t){return"string"==typeof t},isNumber:function(t){return"number"==typeof t},isObject:u,isPlainObject:s,isUndefined:c,isDate:function(t){return"[object Date]"===i.call(t)},isFile:function(t){return"[object File]"===i.call(t)},isBlob:function(t){return"[object Blob]"===i.call(t)},isFunction:p,isStream:function(t){return u(t)&&p(t.pipe)},isURLSearchParams:function(t){return"undefined"!=typeof URLSearchParams&&t instanceof URLSearchParams},isStandardBrowserEnv:function(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&"undefined"!=typeof window&&"undefined"!=typeof document},forEach:f,merge:function t(){var e={};function r(r,n){s(e[n])&&s(r)?e[n]=t(e[n],r):s(r)?e[n]=t({},r):a(r)?e[n]=r.slice():e[n]=r}for(var n=0,o=arguments.length;n<o;n++)f(arguments[n],r);return e},extend:function(t,e,r){return f(e,(function(e,n){t[n]=r&&"function"==typeof e?o(e,r):e})),t},trim:function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")},stripBOM:function(t){return 65279===t.charCodeAt(0)&&(t=t.slice(1)),t}}}},n={};function o(t){var e=n[t];if(void 0!==e)return e.exports;var i=n[t]={exports:{}};return r[t](i,i.exports,o),i.exports}o.m=r,o.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return o.d(e,{a:e}),e},o.d=(t,e)=>{for(var r in e)o.o(e,r)&&!o.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},o.f={},o.e=t=>Promise.all(Object.keys(o.f).reduce(((e,r)=>(o.f[r](t,e),e)),[])),o.u=t=>t+".jibb.js",o.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),o.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),t={},e="JIBB:",o.l=(r,n,i,a)=>{if(t[r])t[r].push(n);else{var c,u;if(void 0!==i)for(var s=document.getElementsByTagName("script"),p=0;p<s.length;p++){var f=s[p];if(f.getAttribute("src")==r||f.getAttribute("data-webpack")==e+i){c=f;break}}c||(u=!0,(c=document.createElement("script")).charset="utf-8",c.timeout=120,o.nc&&c.setAttribute("nonce",o.nc),c.setAttribute("data-webpack",e+i),c.src=r),t[r]=[n];var l=(e,n)=>{c.onerror=c.onload=null,clearTimeout(h);var o=t[r];if(delete t[r],c.parentNode&&c.parentNode.removeChild(c),o&&o.forEach((t=>t(n))),e)return e(n)},h=setTimeout(l.bind(null,void 0,{type:"timeout",target:c}),12e4);c.onerror=l.bind(null,c.onerror),c.onload=l.bind(null,c.onload),u&&document.head.appendChild(c)}},o.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},(()=>{var t;o.g.importScripts&&(t=o.g.location+"");var e=o.g.document;if(!t&&e&&(e.currentScript&&(t=e.currentScript.src),!t)){var r=e.getElementsByTagName("script");r.length&&(t=r[r.length-1].src)}if(!t)throw new Error("Automatic publicPath is not supported in this browser");t=t.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),o.p=t})(),(()=>{var t={179:0};o.f.j=(e,r)=>{var n=o.o(t,e)?t[e]:void 0;if(0!==n)if(n)r.push(n[2]);else{var i=new Promise(((r,o)=>n=t[e]=[r,o]));r.push(n[2]=i);var a=o.p+o.u(e),c=new Error;o.l(a,(r=>{if(o.o(t,e)&&(0!==(n=t[e])&&(t[e]=void 0),n)){var i=r&&("load"===r.type?"missing":r.type),a=r&&r.target&&r.target.src;c.message="Loading chunk "+e+" failed.\n("+i+": "+a+")",c.name="ChunkLoadError",c.type=i,c.request=a,n[1](c)}}),"chunk-"+e,e)}};var e=(e,r)=>{var n,i,[a,c,u]=r,s=0;if(a.some((e=>0!==t[e]))){for(n in c)o.o(c,n)&&(o.m[n]=c[n]);u&&u(o)}for(e&&e(r);s<a.length;s++)i=a[s],o.o(t,i)&&t[i]&&t[i][0](),t[i]=0},r=globalThis.webpackChunkJIBB=globalThis.webpackChunkJIBB||[];r.forEach(e.bind(null,0)),r.push=e.bind(null,r.push.bind(r))})();var i={};return(()=>{"use strict";o.d(i,{default:()=>On});var t={};o.r(t),o.d(t,{shareImage:()=>L});var e={};o.r(e),o.d(e,{createMeeting:()=>Tt,createShare:()=>te,createTemporaryShare:()=>Ot,deleteMeeting:()=>Mt,deleteMeetingImages:()=>At,deleteShare:()=>oe,deleteShareMe:()=>ue,endMeeting:()=>Dt,getListShare:()=>re,getListShareMe:()=>ae,getMeetingDetails:()=>Kt,getMeetingImage:()=>Nt,getMeetingImages:()=>Rt,getMeetingList:()=>Wt,getMeetingToken:()=>Jt,getMeetingTokenFromTempShareId:()=>Ut,isMeetingOwner:()=>Qt,startMeeting:()=>Gt,updateMeeting:()=>Vt});var r={};o.r(r),o.d(r,{createOrganization:()=>we,deleteOrganization:()=>xe,getOrganization:()=>ge,getOrganizationList:()=>ye});var n={};o.r(n),o.d(n,{SendUserActivationEmail:()=>Ge,createDomain:()=>tr,createOrganizationUser:()=>Ne,createUsers:()=>Re,deleteDomain:()=>rr,deleteOrganizationUser:()=>De,deleteSAML:()=>Ke,getDomainList:()=>Qe,getOrganizationDetails:()=>Ue,getOrganizationList:()=>Oe,getOrganizationUserDetails:()=>Je,getSAML:()=>Ve,getUserList:()=>Ae,setSAML:()=>We,updateUserType:()=>Me,verifyDomain:()=>or});var a={};o.r(a),o.d(a,{getCameraList:()=>Nr,getCameraPreview:()=>Gr,getClientStatusList:()=>Kr,sendMessage:()=>Jr,setRuntimeConfig:()=>Wr,startStream:()=>Dr,stopStream:()=>Mr});var c={};function u(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}o.r(c),o.d(c,{deleteImage:()=>bn,deleteRecording:()=>ln,getAllRecordImages:()=>mn,getImage:()=>vn,getImageList:()=>dn,getRecording:()=>un,getRecordingList:()=>pn,startRecording:()=>jn,stopRecording:()=>kn,takeSnapshot:()=>Tn,updateRecording:()=>an});var s=new(function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.apiBaseURL="https://api.jibb.ai"}var e,r;return e=t,(r=[{key:"setApiBaseURL",value:function(t){this.apiBaseURL=t}}])&&u(e.prototype,r),Object.defineProperty(e,"prototype",{writable:!1}),t}()),p=o(806),f=o.n(p);function l(t){return l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},l(t)}function h(){h=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,o){var i=e&&e.prototype instanceof d?e:d,a=Object.create(i.prototype),c=new S(o||[]);return n(a,"_invoke",{value:L(t,r,c)}),a}function p(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=s;var f={};function d(){}function y(){}function v(){}var g={};u(g,i,(function(){return this}));var m=Object.getPrototypeOf,w=m&&m(m(O([])));w&&w!==e&&r.call(w,i)&&(g=w);var b=v.prototype=d.prototype=Object.create(g);function x(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function o(n,i,a,c){var u=p(t[n],t,i);if("throw"!==u.type){var s=u.arg,f=s.value;return f&&"object"==l(f)&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){s.value=t,a(s)}),(function(t){return o("throw",t,a,c)}))}c(u.arg)}var i;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){o(t,r,e,n)}))}return i=i?i.then(n,n):n()}})}function L(t,e,r){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return{value:void 0,done:!0}}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var c=k(a,r);if(c){if(c===f)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var u=p(t,e,r);if("normal"===u.type){if(n=r.done?"completed":"suspendedYield",u.arg===f)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n="completed",r.method="throw",r.arg=u.arg)}}}function k(t,e){var r=t.iterator[e.method];if(void 0===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=void 0,k(t,e),"throw"===e.method))return f;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var n=p(r,t.iterator,e.arg);if("throw"===n.type)return e.method="throw",e.arg=n.arg,e.delegate=null,f;var o=n.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function E(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function T(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function S(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(E,this),this.reset(!0)}function O(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:_}}function _(){return{value:void 0,done:!0}}return y.prototype=v,n(b,"constructor",{value:v,configurable:!0}),n(v,"constructor",{value:y,configurable:!0}),y.displayName=u(v,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===y||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,v):(t.__proto__=v,u(t,c,"GeneratorFunction")),t.prototype=Object.create(b),t},t.awrap=function(t){return{__await:t}},x(j.prototype),u(j.prototype,a,(function(){return this})),t.AsyncIterator=j,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new j(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},x(b),u(b,c,"Generator"),u(b,i,(function(){return this})),u(b,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=O,S.prototype={constructor:S,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(T),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var c=r.call(i,"catchLoc"),u=r.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),T(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;T(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:O(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function d(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function y(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){d(i,n,o,a,c,"next",t)}function c(t){d(i,n,o,a,c,"throw",t)}a(void 0)}))}}function v(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var g=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t)}var e,r,n,o,i,a,c;return e=t,r=[{key:"get",value:(c=y(h().mark((function t(e,r){var n,o=arguments;return h().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return(n=o.length>2&&void 0!==o[2]?o[2]:{}).headers=r,t.abrupt("return",f().get(e,n));case 3:case"end":return t.stop()}}),t)}))),function(t,e){return c.apply(this,arguments)})},{key:"post",value:(a=y(h().mark((function t(e){var r,n,o=arguments;return h().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=o.length>1&&void 0!==o[1]?o[1]:{},n=o.length>2&&void 0!==o[2]?o[2]:{},t.abrupt("return",f().post(e,r,{headers:n}));case 3:case"end":return t.stop()}}),t)}))),function(t){return a.apply(this,arguments)})},{key:"patch",value:(i=y(h().mark((function t(e){var r,n,o=arguments;return h().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=o.length>1&&void 0!==o[1]?o[1]:{},n=o.length>2&&void 0!==o[2]?o[2]:{},t.abrupt("return",f().patch(e,r,{headers:n}));case 3:case"end":return t.stop()}}),t)}))),function(t){return i.apply(this,arguments)})},{key:"put",value:(o=y(h().mark((function t(e){var r,n,o=arguments;return h().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=o.length>1&&void 0!==o[1]?o[1]:{},n=o.length>2&&void 0!==o[2]?o[2]:{},t.abrupt("return",f().put(e,r,{headers:n}));case 3:case"end":return t.stop()}}),t)}))),function(t){return o.apply(this,arguments)})},{key:"delete",value:(n=y(h().mark((function t(e){var r,n=arguments;return h().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=n.length>1&&void 0!==n[1]?n[1]:{},t.abrupt("return",f().delete(e,{headers:r}));case 2:case"end":return t.stop()}}),t)}))),function(t){return n.apply(this,arguments)})}],r&&v(e.prototype,r),Object.defineProperty(e,"prototype",{writable:!1}),t}();globalThis.http=new g;var m=globalThis.http;function w(t){return w="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},w(t)}function b(){b=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,o){var i=e&&e.prototype instanceof l?e:l,a=Object.create(i.prototype),c=new S(o||[]);return n(a,"_invoke",{value:L(t,r,c)}),a}function p(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=s;var f={};function l(){}function h(){}function d(){}var y={};u(y,i,(function(){return this}));var v=Object.getPrototypeOf,g=v&&v(v(O([])));g&&g!==e&&r.call(g,i)&&(y=g);var m=d.prototype=l.prototype=Object.create(y);function x(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function o(n,i,a,c){var u=p(t[n],t,i);if("throw"!==u.type){var s=u.arg,f=s.value;return f&&"object"==w(f)&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){s.value=t,a(s)}),(function(t){return o("throw",t,a,c)}))}c(u.arg)}var i;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){o(t,r,e,n)}))}return i=i?i.then(n,n):n()}})}function L(t,e,r){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return{value:void 0,done:!0}}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var c=k(a,r);if(c){if(c===f)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var u=p(t,e,r);if("normal"===u.type){if(n=r.done?"completed":"suspendedYield",u.arg===f)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n="completed",r.method="throw",r.arg=u.arg)}}}function k(t,e){var r=t.iterator[e.method];if(void 0===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=void 0,k(t,e),"throw"===e.method))return f;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var n=p(r,t.iterator,e.arg);if("throw"===n.type)return e.method="throw",e.arg=n.arg,e.delegate=null,f;var o=n.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function E(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function T(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function S(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(E,this),this.reset(!0)}function O(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:_}}function _(){return{value:void 0,done:!0}}return h.prototype=d,n(m,"constructor",{value:d,configurable:!0}),n(d,"constructor",{value:h,configurable:!0}),h.displayName=u(d,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,d):(t.__proto__=d,u(t,c,"GeneratorFunction")),t.prototype=Object.create(m),t},t.awrap=function(t){return{__await:t}},x(j.prototype),u(j.prototype,a,(function(){return this})),t.AsyncIterator=j,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new j(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},x(m),u(m,c,"Generator"),u(m,i,(function(){return this})),u(m,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=O,S.prototype={constructor:S,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(T),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var c=r.call(i,"catchLoc"),u=r.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),T(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;T(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:O(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function x(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function j(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){x(i,n,o,a,c,"next",t)}function c(t){x(i,n,o,a,c,"throw",t)}a(void 0)}))}}function L(t){return k.apply(this,arguments)}function k(){return(k=j(b().mark((function t(e){var r,n,o,i,a,c;return b().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.meetingToken,n=e.message,o=e.image,i={"Content-Type":"application/json",Accept:"application/json","x-jibb-meeting-jwt":r},a={image:o,message:n},t.next=5,m.post("".concat(s.apiBaseURL,"/v1/webexbot/message"),a,i);case 5:return c=t.sent,t.abrupt("return",c.data);case 7:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function E(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var T=new(function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t)}var e,r;return e=t,(r=[{key:"error",value:function(){}},{key:"debug",value:function(){}},{key:"warn",value:function(){}},{key:"info",value:function(){}},{key:"setLevel",value:function(){}}])&&E(e.prototype,r),Object.defineProperty(e,"prototype",{writable:!1}),t}());function S(t){this.message=t}S.prototype=new Error,S.prototype.name="InvalidCharacterError";var O="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(t){var e=String(t).replace(/=+$/,"");if(e.length%4==1)throw new S("'atob' failed: The string to be decoded is not correctly encoded.");for(var r,n,o=0,i=0,a="";n=e.charAt(i++);~n&&(r=o%4?64*r+n:n,o++%4)?a+=String.fromCharCode(255&r>>(-2*o&6)):0)n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(n);return a};function _(t){var e=t.replace(/-/g,"+").replace(/_/g,"/");switch(e.length%4){case 0:break;case 2:e+="==";break;case 3:e+="=";break;default:throw"Illegal base64url string!"}try{return function(t){return decodeURIComponent(O(t).replace(/(.)/g,(function(t,e){var r=e.charCodeAt(0).toString(16).toUpperCase();return r.length<2&&(r="0"+r),"%"+r})))}(e)}catch(t){return O(e)}}function U(t){this.message=t}U.prototype=new Error,U.prototype.name="InvalidTokenError";const P=function(t,e){if("string"!=typeof t)throw new U("Invalid token specified");var r=!0===(e=e||{}).header?0:1;try{return JSON.parse(_(t.split(".")[r]))}catch(t){throw new U("Invalid token specified: "+t.message)}};function A(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function C(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function R(t,e,r){return e&&C(t.prototype,e),r&&C(t,r),Object.defineProperty(t,"prototype",{writable:!1}),t}var I="USER",N="ADMIN",B="SUPERADMIN",G=function(){function t(e){A(this,t),this.claims=P(e),this.expiryTime=new Date(1e3*this.claims.exp),this.owner=this.claims.data.owner,this.meetindId=this.claims.data.meeting_id,this.title=this.claims.data.title,this.capacity=this.claims.data.capacity,this.permission=this.claims.data.permission,this.meetingType=this.claims.data.meeting_type,this.isTemporary=this.claims.data.is_temporary}return R(t,[{key:"getSecondsUntilExpiry",value:function(){return this.expiryTime-Date.now()-60}},{key:"isExpired",value:function(){return this.getSecondsUntilExpiry()<=0}}]),t}(),F=function(){function t(e){var r;A(this,t),this.token=e,this.claims=P(e),this.expiryTime=new Date(1e3*this.claims.exp),this.email=null===(r=this.claims.data)||void 0===r?void 0:r.email,this.userId=this.claims.sub}return R(t,[{key:"getSecondsUntilExpiry",value:function(){return this.expiryTime-Date.now()-60}},{key:"isExpired",value:function(){return this.getSecondsUntilExpiry()<=0}},{key:"getUserId",value:function(){return this.userId}}]),t}();function D(t){return D="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},D(t)}function z(){z=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,o){var i=e&&e.prototype instanceof l?e:l,a=Object.create(i.prototype),c=new E(o||[]);return n(a,"_invoke",{value:x(t,r,c)}),a}function p(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=s;var f={};function l(){}function h(){}function d(){}var y={};u(y,i,(function(){return this}));var v=Object.getPrototypeOf,g=v&&v(v(T([])));g&&g!==e&&r.call(g,i)&&(y=g);var m=d.prototype=l.prototype=Object.create(y);function w(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function b(t,e){function o(n,i,a,c){var u=p(t[n],t,i);if("throw"!==u.type){var s=u.arg,f=s.value;return f&&"object"==D(f)&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){s.value=t,a(s)}),(function(t){return o("throw",t,a,c)}))}c(u.arg)}var i;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){o(t,r,e,n)}))}return i=i?i.then(n,n):n()}})}function x(t,e,r){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return{value:void 0,done:!0}}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var c=j(a,r);if(c){if(c===f)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var u=p(t,e,r);if("normal"===u.type){if(n=r.done?"completed":"suspendedYield",u.arg===f)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n="completed",r.method="throw",r.arg=u.arg)}}}function j(t,e){var r=t.iterator[e.method];if(void 0===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=void 0,j(t,e),"throw"===e.method))return f;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var n=p(r,t.iterator,e.arg);if("throw"===n.type)return e.method="throw",e.arg=n.arg,e.delegate=null,f;var o=n.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function L(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function k(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function E(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(L,this),this.reset(!0)}function T(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:S}}function S(){return{value:void 0,done:!0}}return h.prototype=d,n(m,"constructor",{value:d,configurable:!0}),n(d,"constructor",{value:h,configurable:!0}),h.displayName=u(d,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,d):(t.__proto__=d,u(t,c,"GeneratorFunction")),t.prototype=Object.create(m),t},t.awrap=function(t){return{__await:t}},w(b.prototype),u(b.prototype,a,(function(){return this})),t.AsyncIterator=b,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new b(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(m),u(m,c,"Generator"),u(m,i,(function(){return this})),u(m,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=T,E.prototype={constructor:E,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(k),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var c=r.call(i,"catchLoc"),u=r.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:T(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function M(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function q(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){M(i,n,o,a,c,"next",t)}function c(t){M(i,n,o,a,c,"throw",t)}a(void 0)}))}}function J(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function Y(t,e){W(t,e),e.add(t)}function W(t,e){if(e.has(t))throw new TypeError("Cannot initialize the same private elements twice on an object")}function H(t,e,r){if(!e.has(t))throw new TypeError("attempted to get private field on non-instance");return r}function K(t,e){return function(t,e){return e.get?e.get.call(t):e.value}(t,$(t,e,"get"))}function $(t,e,r){if(!e.has(t))throw new TypeError("attempted to "+r+" private field on non-instance");return e.get(t)}var V=new WeakMap,X=new WeakSet,Q=new WeakSet,Z=new WeakSet,tt=function(){function t(){var e,r;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),Y(this,Z),Y(this,Q),Y(this,X),r={writable:!0,value:void 0},W(this,e=V),e.set(this,r),T.debug("Creating new Auth instance"),this.apiKey=void 0,function(t,e,r){(function(t,e,r){if(e.set)e.set.call(t,r);else{if(!e.writable)throw new TypeError("attempted to set read only private field");e.value=r}})(t,$(t,e,"set"),r)}(this,V,new Map),this.getIdToken=void 0}var e,r,n,o,i,a;return e=t,r=[{key:"setUserToken",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:I,r=new F(t);K(this,V).set(e,r)}},{key:"setApiKey",value:function(t){this.apiKey=t,K(this,V).clear()}},{key:"getUserClaims",value:(a=q(z().mark((function t(){return z().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.getUserToken();case 2:return t.abrupt("return",K(this,V).get(I));case 3:case"end":return t.stop()}}),t,this)}))),function(){return a.apply(this,arguments)})},{key:"getUserToken",value:(i=q(z().mark((function t(){var e,r,n,o,i,a=arguments;return z().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(e=a.length>0&&void 0!==a[0]?a[0]:{},r=e.expiry,n=e.refresh,o=e.accessLevel,i=void 0,o=o||I,r=r||3600,!0!==(n=n||!1)){t.next=8;break}return t.next=8,H(this,Z,it).call(this,{expiry:r,accessLevel:o});case 8:if(void 0===(i=K(this,V).get(o))||i.isExpired()){t.next=11;break}return t.abrupt("return",i.token);case 11:return t.next=13,H(this,Z,it).call(this,{expiry:r,accessLevel:o});case 13:if(void 0===(i=K(this,V).get(o))||i.isExpired()){t.next=16;break}return t.abrupt("return",i.token);case 16:throw new Error("could not create user token");case 17:case"end":return t.stop()}}),t,this)}))),function(){return i.apply(this,arguments)})},{key:"logout",value:function(){K(this,V).clear()}},{key:"generateAPIKey",value:(o=q(z().mark((function t(){var e,r;return z().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.getUserToken();case 2:return t.t0=t.sent,e={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=6,m.get("".concat(s.apiBaseURL,"/v1/auth/apikey"),e);case 6:return r=t.sent,t.abrupt("return",r.data.apiKey);case 8:case"end":return t.stop()}}),t,this)}))),function(){return o.apply(this,arguments)})},{key:"generateCustomAuthPassword",value:(n=q(z().mark((function t(){var e,r;return z().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.getIdToken();case 2:return t.t0=t.sent,e={"Content-Type":"application/json",Accept:"application/json","x-jibb-id-jwt":t.t0},t.next=6,m.get("".concat(s.apiBaseURL,"/v1/auth/custom"),e);case 6:return r=t.sent,t.abrupt("return",r.data.password);case 8:case"end":return t.stop()}}),t,this)}))),function(){return n.apply(this,arguments)})}],r&&J(e.prototype,r),Object.defineProperty(e,"prototype",{writable:!1}),t}();function et(t){return rt.apply(this,arguments)}function rt(){return rt=q(z().mark((function t(e){var r,n,o,i,a,c;return z().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:r=e.expiry,n=e.accessLevel,o={"Content-Type":"application/json",Accept:"application/json"},i={api_key:this.apiKey,expiry:{seconds:r}},t.t0=n,t.next=t.t0===N?6:t.t0===B?8:10;break;case 6:return a="".concat(s.apiBaseURL,"/v1/admin/auth/token"),t.abrupt("break",12);case 8:return a="".concat(s.apiBaseURL,"/v1/superadmin/auth/token"),t.abrupt("break",12);case 10:return a="".concat(s.apiBaseURL,"/v1/auth/token"),t.abrupt("break",12);case 12:return t.next=14,m.post(a,i,o);case 14:return c=t.sent,t.abrupt("return",c.data.token);case 16:case"end":return t.stop()}}),t,this)}))),rt.apply(this,arguments)}function nt(t){return ot.apply(this,arguments)}function ot(){return ot=q(z().mark((function t(e){var r,n,o,i,a,c;return z().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.expiry,n=e.accessLevel,t.next=3,this.getIdToken();case 3:t.t0=t.sent,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-id-jwt":t.t0},i={expiry:{seconds:r}},t.t1=n,t.next=t.t1===N?9:t.t1===B?11:13;break;case 9:return a="".concat(s.apiBaseURL,"/v1/admin/auth/token"),t.abrupt("break",15);case 11:return a="".concat(s.apiBaseURL,"/v1/superadmin/auth/token"),t.abrupt("break",15);case 13:return a="".concat(s.apiBaseURL,"/v1/auth/token"),t.abrupt("break",15);case 15:return t.next=17,m.post(a,i,o);case 17:return c=t.sent,t.abrupt("return",c.data.token);case 19:case"end":return t.stop()}}),t,this)}))),ot.apply(this,arguments)}function it(t){return at.apply(this,arguments)}function at(){return at=q(z().mark((function t(e){var r,n,o,i;return z().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(r=e.expiry,n=e.accessLevel,!this.apiKey){t.next=7;break}return t.next=4,H(this,X,et).call(this,{expiry:r,accessLevel:n});case 4:return o=t.sent,this.setUserToken(o,n),t.abrupt("return",o);case 7:return t.prev=7,t.next=10,H(this,Q,nt).call(this,{expiry:r,accessLevel:n});case 10:return i=t.sent,this.setUserToken(i,n),t.abrupt("return",i);case 15:t.prev=15,t.t0=t.catch(7),T.error(t.t0);case 18:case"end":return t.stop()}}),t,this,[[7,15]])}))),at.apply(this,arguments)}var ct=new tt;function ut(t){return ut="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ut(t)}function st(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function pt(t,e,r){return e&&st(t.prototype,e),r&&st(t,r),Object.defineProperty(t,"prototype",{writable:!1}),t}function ft(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function lt(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&mt(t,e)}function ht(t){var e=gt();return function(){var r,n=wt(t);if(e){var o=wt(this).constructor;r=Reflect.construct(n,arguments,o)}else r=n.apply(this,arguments);return dt(this,r)}}function dt(t,e){if(e&&("object"===ut(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}function yt(t){var e="function"==typeof Map?new Map:void 0;return yt=function(t){if(null===t||(r=t,-1===Function.toString.call(r).indexOf("[native code]")))return t;var r;if("function"!=typeof t)throw new TypeError("Super expression must either be null or a function");if(void 0!==e){if(e.has(t))return e.get(t);e.set(t,n)}function n(){return vt(t,arguments,wt(this).constructor)}return n.prototype=Object.create(t.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),mt(n,t)},yt(t)}function vt(t,e,r){return vt=gt()?Reflect.construct.bind():function(t,e,r){var n=[null];n.push.apply(n,e);var o=new(Function.bind.apply(t,n));return r&&mt(o,r.prototype),o},vt.apply(null,arguments)}function gt(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function mt(t,e){return mt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},mt(t,e)}function wt(t){return wt=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},wt(t)}var bt=function(t){lt(r,t);var e=ht(r);function r(t){var n;return ft(this,r),(n=e.call(this,t)).name="NotFoundError",n}return pt(r)}(yt(Error)),xt=(Error,Error,Error,Error,function(t){lt(r,t);var e=ht(r);function r(t){var n;return ft(this,r),(n=e.call(this,t)).name="PermissionDeniedError",n}return pt(r)}(yt(Error)));function jt(t){return jt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},jt(t)}function Lt(){Lt=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,o){var i=e&&e.prototype instanceof l?e:l,a=Object.create(i.prototype),c=new E(o||[]);return n(a,"_invoke",{value:x(t,r,c)}),a}function p(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=s;var f={};function l(){}function h(){}function d(){}var y={};u(y,i,(function(){return this}));var v=Object.getPrototypeOf,g=v&&v(v(T([])));g&&g!==e&&r.call(g,i)&&(y=g);var m=d.prototype=l.prototype=Object.create(y);function w(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function b(t,e){function o(n,i,a,c){var u=p(t[n],t,i);if("throw"!==u.type){var s=u.arg,f=s.value;return f&&"object"==jt(f)&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){s.value=t,a(s)}),(function(t){return o("throw",t,a,c)}))}c(u.arg)}var i;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){o(t,r,e,n)}))}return i=i?i.then(n,n):n()}})}function x(t,e,r){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return{value:void 0,done:!0}}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var c=j(a,r);if(c){if(c===f)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var u=p(t,e,r);if("normal"===u.type){if(n=r.done?"completed":"suspendedYield",u.arg===f)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n="completed",r.method="throw",r.arg=u.arg)}}}function j(t,e){var r=t.iterator[e.method];if(void 0===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=void 0,j(t,e),"throw"===e.method))return f;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var n=p(r,t.iterator,e.arg);if("throw"===n.type)return e.method="throw",e.arg=n.arg,e.delegate=null,f;var o=n.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function L(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function k(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function E(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(L,this),this.reset(!0)}function T(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:S}}function S(){return{value:void 0,done:!0}}return h.prototype=d,n(m,"constructor",{value:d,configurable:!0}),n(d,"constructor",{value:h,configurable:!0}),h.displayName=u(d,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,d):(t.__proto__=d,u(t,c,"GeneratorFunction")),t.prototype=Object.create(m),t},t.awrap=function(t){return{__await:t}},w(b.prototype),u(b.prototype,a,(function(){return this})),t.AsyncIterator=b,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new b(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(m),u(m,c,"Generator"),u(m,i,(function(){return this})),u(m,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=T,E.prototype={constructor:E,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(k),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var c=r.call(i,"catchLoc"),u=r.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:T(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function kt(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function Et(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){kt(i,n,o,a,c,"next",t)}function c(t){kt(i,n,o,a,c,"throw",t)}a(void 0)}))}}function Tt(t){return St.apply(this,arguments)}function St(){return(St=Et(Lt().mark((function t(e){var r,n,o,i,a,c,u;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.title,n=e.isTemporary,o=e.capacity,i=e.meetingType,t.next=3,ct.getUserToken();case 3:return t.t0=t.sent,a={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},c={title:r||"",isTemporary:n||!1,capacity:o||2,meetingType:i||0},t.next=8,m.post("".concat(s.apiBaseURL,"/v1/meetings"),c,a);case 8:return u=t.sent,t.abrupt("return",u.data.meetingId);case 10:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Ot(t){return _t.apply(this,arguments)}function _t(){return(_t=Et(Lt().mark((function t(e){var r,n,o,i,a,c,u;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.meetingId,n=e.permission,o=e.expiry,i=e.auxData,t.next=3,ct.getUserToken();case 3:return t.t0=t.sent,a={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},c={permission:n,expiry:{seconds:o||3600},auxilary:i||{}},t.next=8,m.post("".concat(s.apiBaseURL,"/v1/meetings/").concat(r,"/temp-shares"),c,a);case 8:return u=t.sent,t.abrupt("return",u.data.shareId);case 10:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Ut(t){return Pt.apply(this,arguments)}function Pt(){return(Pt=Et(Lt().mark((function t(e){var r,n,o,i;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.meetingId,n=e.shareId,o={"Content-Type":"application/json",Accept:"application/json"},t.next=4,m.get("".concat(s.apiBaseURL,"/v1/meetings/").concat(r,"/temp-shares/").concat(n),o);case 4:return i=t.sent,t.abrupt("return",i.data.token);case 6:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function At(t){return Ct.apply(this,arguments)}function Ct(){return(Ct=Et(Lt().mark((function t(e){var r,n,o;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.meetingId,n=e.mtoken,t.next=3,ct.getUserToken();case 3:return t.t0=t.sent,t.t1=n,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0,"x-jibb-meeting-jwt":t.t1},t.abrupt("return",m.delete("".concat(s.apiBaseURL,"/v1/meetings/").concat(r,"/images"),o));case 7:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Rt(t){return It.apply(this,arguments)}function It(){return(It=Et(Lt().mark((function t(e){var r,n,o,i;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.meetingId,n=e.meetingToken,t.next=3,ct.getUserToken();case 3:return t.t0=t.sent,t.t1=n,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0,"x-jibb-meeting-jwt":t.t1},t.next=8,m.get("".concat(s.apiBaseURL,"/v1/meetings/").concat(r,"/images"),o);case 8:return i=t.sent,t.abrupt("return",i.data);case 10:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Nt(t){return Bt.apply(this,arguments)}function Bt(){return(Bt=Et(Lt().mark((function t(e){var r,n,o,i,a;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.meetingId,n=e.meetingToken,o=e.imageId,t.next=3,ct.getUserToken();case 3:return t.t0=t.sent,t.t1=n,i={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0,"x-jibb-meeting-jwt":t.t1},t.next=8,m.get("".concat(s.apiBaseURL,"/v1/meetings/").concat(r,"/images/").concat(o),i);case 8:return a=t.sent,t.abrupt("return",a.data);case 10:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Gt(t){return Ft.apply(this,arguments)}function Ft(){return(Ft=Et(Lt().mark((function t(e){var r,n,o,i,a;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.meetingId,n=e.meetingToken,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-meeting-jwt":n},t.prev=2,i={},t.next=6,m.post("".concat(s.apiBaseURL,"/v1/meetings/").concat(r,"/actions/start"),i,o);case 6:return t.abrupt("return",t.sent);case 9:if(t.prev=9,t.t0=t.catch(2),404!=(null===t.t0||void 0===t.t0||null===(a=t.t0.response)||void 0===a?void 0:a.status)){t.next=15;break}throw new bt;case 15:throw t.t0;case 16:case"end":return t.stop()}}),t,null,[[2,9]])})))).apply(this,arguments)}function Dt(t){return zt.apply(this,arguments)}function zt(){return(zt=Et(Lt().mark((function t(e){var r,n,o,i;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.meetingId,n=e.meetingToken,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-meeting-jwt":n},i={},t.abrupt("return",m.post("".concat(s.apiBaseURL,"/v1/meetings/").concat(r,"/actions/end"),i,o));case 4:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Mt(t){return qt.apply(this,arguments)}function qt(){return(qt=Et(Lt().mark((function t(e){var r;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.abrupt("return",m.delete("".concat(s.apiBaseURL,"/v1/meetings/").concat(e),r));case 5:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Jt(t){return Yt.apply(this,arguments)}function Yt(){return(Yt=Et(Lt().mark((function t(e){var r,n,o,i,a,c,u,p;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.meetingId,n=e.permission,o=e.expiry,i=void 0===o?3600:o,t.prev=1,t.next=4,ct.getUserToken();case 4:a=t.sent,t.next=11;break;case 7:throw t.prev=7,t.t0=t.catch(1),T.error({err:t.t0}),new xt("user is not authenticated");case 11:return t.prev=11,c={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":a},t.next=15,m.get("".concat(s.apiBaseURL,"/v1/meetings/").concat(r,"/token/").concat(n,"?expiry.seconds=").concat(i),c);case 15:return u=t.sent,t.abrupt("return",u.data.token);case 19:if(t.prev=19,t.t1=t.catch(11),404!=(null===t.t1||void 0===t.t1||null===(p=t.t1.response)||void 0===p?void 0:p.status)){t.next=25;break}throw new bt("meeting not found");case 25:throw t.t1;case 26:case"end":return t.stop()}}),t,null,[[1,7],[11,19]])})))).apply(this,arguments)}function Wt(t){return Ht.apply(this,arguments)}function Ht(){return(Ht=Et(Lt().mark((function t(e){var r,n;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},void 0!==e&&(r["x-jibb-pagination"]=JSON.stringify(e)),t.next=7,m.get("".concat(s.apiBaseURL,"/v1/meetings"),r);case 7:return n=t.sent,e=(e=n.headers["x-jibb-pagination"])&&JSON.parse(e),t.abrupt("return",{meetings:n.data.meetings,pagination:e});case 11:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Kt(t){return $t.apply(this,arguments)}function $t(){return($t=Et(Lt().mark((function t(e){var r,n;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=6,m.get("".concat(s.apiBaseURL,"/v1/meetings/").concat(e),r);case 6:return n=t.sent,t.abrupt("return",n.data);case 8:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Vt(t){return Xt.apply(this,arguments)}function Xt(){return(Xt=Et(Lt().mark((function t(e){var r,n,o,i,a;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.meetingId,n=e.title,o=e.capacity,t.next=3,ct.getUserToken();case 3:return t.t0=t.sent,i={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},a={},n&&(a.title=n),o&&(a.capacity=o),t.abrupt("return",m.post("".concat(s.apiBaseURL,"/v1/meetings/").concat(r),a,i));case 9:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Qt(t){return Zt.apply(this,arguments)}function Zt(){return(Zt=Et(Lt().mark((function t(e){var r,n;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,r=new G(e),t.t0=F,t.next=5,ct.getUserToken();case 5:return t.t1=t.sent,n=new t.t0(t.t1),t.abrupt("return",n.email===r.owner);case 10:return t.prev=10,t.t2=t.catch(0),t.abrupt("return",!1);case 13:case"end":return t.stop()}}),t,null,[[0,10]])})))).apply(this,arguments)}function te(t){return ee.apply(this,arguments)}function ee(){return(ee=Et(Lt().mark((function t(e){var r,n,o,i,a,c,u;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.email,n=e.meetingId,o=e.permission,i=e.meetingToken,t.next=3,ct.getUserToken();case 3:return t.t0=t.sent,t.t1=i,a={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0,"x-jibb-meeting-jwt":t.t1},c={email:r,permission:o},t.next=9,m.post("".concat(s.apiBaseURL,"/v1/meetings/").concat(n,"/shares"),c,a);case 9:return u=t.sent,t.abrupt("return",u.data);case 11:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function re(t){return ne.apply(this,arguments)}function ne(){return(ne=Et(Lt().mark((function t(e){var r,n,o,i;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.meetingId,n=e.meetingToken,t.next=3,ct.getUserToken();case 3:return t.t0=t.sent,t.t1=n,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0,"x-jibb-meeting-jwt":t.t1},t.next=8,m.get("".concat(s.apiBaseURL,"/v1/meetings/").concat(r,"/shares"),o);case 8:return i=t.sent,t.abrupt("return",i.data.shares);case 10:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function oe(t){return ie.apply(this,arguments)}function ie(){return(ie=Et(Lt().mark((function t(e){var r,n,o,i;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.meetingId,n=e.userId,o=e.meetingToken,t.next=3,ct.getUserToken();case 3:return t.t0=t.sent,t.t1=o,i={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0,"x-jibb-meeting-jwt":t.t1},t.abrupt("return",m.delete("".concat(s.apiBaseURL,"/v1/meetings/").concat(r,"/shares/").concat(n),i));case 7:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function ae(){return ce.apply(this,arguments)}function ce(){return(ce=Et(Lt().mark((function t(){var e,r;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,e={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=6,m.get("".concat(s.apiBaseURL,"/v1/meetings/shares"),e);case 6:return r=t.sent,t.abrupt("return",r.data.shares);case 8:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function ue(t){return se.apply(this,arguments)}function se(){return(se=Et(Lt().mark((function t(e){var r;return Lt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.abrupt("return",m.delete("".concat(s.apiBaseURL,"/v1/meetings/shares/").concat(e),r));case 5:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function pe(t){return pe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},pe(t)}function fe(){fe=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,o){var i=e&&e.prototype instanceof l?e:l,a=Object.create(i.prototype),c=new E(o||[]);return n(a,"_invoke",{value:x(t,r,c)}),a}function p(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=s;var f={};function l(){}function h(){}function d(){}var y={};u(y,i,(function(){return this}));var v=Object.getPrototypeOf,g=v&&v(v(T([])));g&&g!==e&&r.call(g,i)&&(y=g);var m=d.prototype=l.prototype=Object.create(y);function w(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function b(t,e){function o(n,i,a,c){var u=p(t[n],t,i);if("throw"!==u.type){var s=u.arg,f=s.value;return f&&"object"==pe(f)&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){s.value=t,a(s)}),(function(t){return o("throw",t,a,c)}))}c(u.arg)}var i;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){o(t,r,e,n)}))}return i=i?i.then(n,n):n()}})}function x(t,e,r){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return{value:void 0,done:!0}}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var c=j(a,r);if(c){if(c===f)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var u=p(t,e,r);if("normal"===u.type){if(n=r.done?"completed":"suspendedYield",u.arg===f)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n="completed",r.method="throw",r.arg=u.arg)}}}function j(t,e){var r=t.iterator[e.method];if(void 0===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=void 0,j(t,e),"throw"===e.method))return f;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var n=p(r,t.iterator,e.arg);if("throw"===n.type)return e.method="throw",e.arg=n.arg,e.delegate=null,f;var o=n.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function L(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function k(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function E(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(L,this),this.reset(!0)}function T(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:S}}function S(){return{value:void 0,done:!0}}return h.prototype=d,n(m,"constructor",{value:d,configurable:!0}),n(d,"constructor",{value:h,configurable:!0}),h.displayName=u(d,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,d):(t.__proto__=d,u(t,c,"GeneratorFunction")),t.prototype=Object.create(m),t},t.awrap=function(t){return{__await:t}},w(b.prototype),u(b.prototype,a,(function(){return this})),t.AsyncIterator=b,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new b(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(m),u(m,c,"Generator"),u(m,i,(function(){return this})),u(m,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=T,E.prototype={constructor:E,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(k),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var c=r.call(i,"catchLoc"),u=r.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:T(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function le(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function he(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){le(i,n,o,a,c,"next",t)}function c(t){le(i,n,o,a,c,"throw",t)}a(void 0)}))}}Error;var de=B;function ye(){return ve.apply(this,arguments)}function ve(){return(ve=he(fe().mark((function t(){var e,r;return fe().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken({accessLevel:de});case 2:return t.t0=t.sent,e={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=6,m.get("".concat(s.apiBaseURL,"/v1/superadmin/organizations"),e);case 6:return r=t.sent,t.abrupt("return",r.data.organizations);case 8:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function ge(t){return me.apply(this,arguments)}function me(){return(me=he(fe().mark((function t(e){var r,n;return fe().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(""!==e){t.next=2;break}throw new Error("organization ID can not be empty");case 2:return t.next=4,ct.getUserToken({accessLevel:de});case 4:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=8,m.get("".concat(s.apiBaseURL,"/v1/superadmin/organizations/").concat(e),r);case 8:return n=t.sent,t.abrupt("return",n.data);case 10:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function we(t){return be.apply(this,arguments)}function be(){return(be=he(fe().mark((function t(e){var r,n,o,i,a,c,u;return fe().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.organizationName,n=e.ownerEmail,o=e.level,i=e.licenseCount,a=e.expiryDate,t.next=3,ct.getUserToken({accessLevel:de});case 3:return t.t0=t.sent,c={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},u={name:r,owner_email:n,level:o,license_count:i,expiry_date:a},t.abrupt("return",m.post("".concat(s.apiBaseURL,"/v1/superadmin/organizations/"),u,c));case 7:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function xe(t){return je.apply(this,arguments)}function je(){return(je=he(fe().mark((function t(e){var r;return fe().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken({accessLevel:de});case 2:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.abrupt("return",m.delete("".concat(s.apiBaseURL,"/v1/superadmin/organizations/").concat(e),r));case 5:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Le(t){return Le="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Le(t)}function ke(){ke=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,o){var i=e&&e.prototype instanceof l?e:l,a=Object.create(i.prototype),c=new E(o||[]);return n(a,"_invoke",{value:x(t,r,c)}),a}function p(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=s;var f={};function l(){}function h(){}function d(){}var y={};u(y,i,(function(){return this}));var v=Object.getPrototypeOf,g=v&&v(v(T([])));g&&g!==e&&r.call(g,i)&&(y=g);var m=d.prototype=l.prototype=Object.create(y);function w(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function b(t,e){function o(n,i,a,c){var u=p(t[n],t,i);if("throw"!==u.type){var s=u.arg,f=s.value;return f&&"object"==Le(f)&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){s.value=t,a(s)}),(function(t){return o("throw",t,a,c)}))}c(u.arg)}var i;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){o(t,r,e,n)}))}return i=i?i.then(n,n):n()}})}function x(t,e,r){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return{value:void 0,done:!0}}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var c=j(a,r);if(c){if(c===f)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var u=p(t,e,r);if("normal"===u.type){if(n=r.done?"completed":"suspendedYield",u.arg===f)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n="completed",r.method="throw",r.arg=u.arg)}}}function j(t,e){var r=t.iterator[e.method];if(void 0===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=void 0,j(t,e),"throw"===e.method))return f;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var n=p(r,t.iterator,e.arg);if("throw"===n.type)return e.method="throw",e.arg=n.arg,e.delegate=null,f;var o=n.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function L(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function k(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function E(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(L,this),this.reset(!0)}function T(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:S}}function S(){return{value:void 0,done:!0}}return h.prototype=d,n(m,"constructor",{value:d,configurable:!0}),n(d,"constructor",{value:h,configurable:!0}),h.displayName=u(d,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,d):(t.__proto__=d,u(t,c,"GeneratorFunction")),t.prototype=Object.create(m),t},t.awrap=function(t){return{__await:t}},w(b.prototype),u(b.prototype,a,(function(){return this})),t.AsyncIterator=b,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new b(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(m),u(m,c,"Generator"),u(m,i,(function(){return this})),u(m,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=T,E.prototype={constructor:E,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(k),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var c=r.call(i,"catchLoc"),u=r.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:T(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function Ee(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function Te(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){Ee(i,n,o,a,c,"next",t)}function c(t){Ee(i,n,o,a,c,"throw",t)}a(void 0)}))}}var Se=N;function Oe(){return _e.apply(this,arguments)}function _e(){return(_e=Te(ke().mark((function t(){var e,r;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken({accessLevel:Se});case 2:return t.t0=t.sent,e={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=6,m.get("".concat(s.apiBaseURL,"/v1/admin/organizations"),e);case 6:return r=t.sent,t.abrupt("return",r.data.organizations);case 8:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Ue(t){return Pe.apply(this,arguments)}function Pe(){return(Pe=Te(ke().mark((function t(e){var r,n;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(""!==e){t.next=2;break}throw new Error("organization ID can not be empty");case 2:return t.next=4,ct.getUserToken({accessLevel:Se});case 4:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=8,m.get("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(e),r);case 8:return n=t.sent,t.abrupt("return",n.data);case 10:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Ae(t,e){return Ce.apply(this,arguments)}function Ce(){return(Ce=Te(ke().mark((function t(e,r){var n,o;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken({accessLevel:Se});case 2:return t.t0=t.sent,n={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},void 0!==r&&(n["x-jibb-pagination"]=JSON.stringify(r)),t.next=7,m.get("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(e,"/users"),n);case 7:return o=t.sent,r=(r=o.headers["x-jibb-pagination"])&&JSON.parse(r),t.abrupt("return",{users:o.data.users,pagination:r});case 11:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Re(t){return Ie.apply(this,arguments)}function Ie(){return(Ie=Te(ke().mark((function t(e){var r,n,o,i;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.orgId,n=e.users,t.next=3,ct.getUserToken({accessLevel:Se});case 3:return t.t0=t.sent,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},i={users:n},t.abrupt("return",m.post("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(r,"/users"),i,o));case 7:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Ne(t){return Be.apply(this,arguments)}function Be(){return(Be=Te(ke().mark((function t(e){var r,n,o,i,a;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.orgId,n=e.email,o=e.userType,t.next=3,ct.getUserToken({accessLevel:Se});case 3:return t.t0=t.sent,i={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},a={users:[{email:n,user_type:o}]},t.abrupt("return",m.post("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(r,"/users"),a,i));case 7:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Ge(t){return Fe.apply(this,arguments)}function Fe(){return(Fe=Te(ke().mark((function t(e){var r,n,o,i;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.orgId,n=e.userIds,t.next=3,ct.getUserToken({accessLevel:Se});case 3:return t.t0=t.sent,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},i={user_ids:n},t.abrupt("return",m.post("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(r,"/activation/email"),i,o));case 7:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function De(t){return ze.apply(this,arguments)}function ze(){return(ze=Te(ke().mark((function t(e){var r,n,o;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.orgId,n=e.userId,t.next=3,ct.getUserToken({accessLevel:Se});case 3:return t.t0=t.sent,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.abrupt("return",m.delete("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(r,"/users/").concat(n),o));case 6:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Me(t){return qe.apply(this,arguments)}function qe(){return(qe=Te(ke().mark((function t(e){var r,n,o,i,a;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.orgId,n=e.userId,o=e.userType,t.next=3,ct.getUserToken({accessLevel:Se});case 3:return t.t0=t.sent,i={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},a={user_type:o},t.abrupt("return",m.patch("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(r,"/users/").concat(n),a,i));case 7:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Je(t){return Ye.apply(this,arguments)}function Ye(){return(Ye=Te(ke().mark((function t(e){var r,n,o,i;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.orgId,n=e.userId,t.next=3,ct.getUserToken({accessLevel:Se});case 3:return t.t0=t.sent,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=7,m.get("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(r,"/users/").concat(n),o);case 7:return i=t.sent,t.abrupt("return",i.data);case 9:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function We(t){return He.apply(this,arguments)}function He(){return(He=Te(ke().mark((function t(e){var r,n,o,i,a,c,u;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(r=e.orgId,n=e.metadata,o=e.autoAddUsers,i=e.defaultUserType,a=e.enabled,""!==r&&void 0!==r){t.next=3;break}throw new Error("organization ID can not be empty");case 3:return t.next=5,ct.getUserToken({accessLevel:Se});case 5:return t.t0=t.sent,c={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},u={organization_id:r,metadata:n||"",auto_add_users:void 0!==o&&o,default_user_type:void 0!==i?i:0,enabled:a||!1},t.abrupt("return",m.put("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(r,"/saml"),u,c));case 9:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Ke(t){return $e.apply(this,arguments)}function $e(){return($e=Te(ke().mark((function t(e){var r;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken({accessLevel:Se});case 2:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.abrupt("return",m.delete("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(e,"/saml"),r));case 5:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Ve(t){return Xe.apply(this,arguments)}function Xe(){return(Xe=Te(ke().mark((function t(e){var r,n;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(""!==e){t.next=2;break}throw new Error("organization ID can not be empty");case 2:return t.next=4,ct.getUserToken({accessLevel:Se});case 4:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=8,m.get("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(e,"/saml"),r);case 8:return n=t.sent,t.abrupt("return",n.data);case 10:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Qe(t){return Ze.apply(this,arguments)}function Ze(){return(Ze=Te(ke().mark((function t(e){var r,n;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken({accessLevel:Se});case 2:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=6,m.get("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(e,"/domains"),r);case 6:return n=t.sent,t.abrupt("return",n.data);case 8:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function tr(t){return er.apply(this,arguments)}function er(){return(er=Te(ke().mark((function t(e){var r,n,o,i,a;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.orgId,n=e.domain,t.next=3,ct.getUserToken({accessLevel:Se});case 3:return t.t0=t.sent,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},i={domain_name:n},t.next=8,m.post("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(r,"/domains"),i,o);case 8:return a=t.sent,t.abrupt("return",a.data);case 10:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function rr(t){return nr.apply(this,arguments)}function nr(){return(nr=Te(ke().mark((function t(e){var r,n,o;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.orgId,n=e.domainId,t.next=3,ct.getUserToken({accessLevel:Se});case 3:return t.t0=t.sent,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.abrupt("return",m.delete("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(r,"/domains/").concat(n),o));case 6:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function or(t){return ir.apply(this,arguments)}function ir(){return(ir=Te(ke().mark((function t(e){var r,n,o,i;return ke().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.orgId,n=e.domainId,t.next=3,ct.getUserToken({accessLevel:Se});case 3:return t.t0=t.sent,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=7,m.get("".concat(s.apiBaseURL,"/v1/admin/organizations/").concat(r,"/domains/").concat(n,"/verify"),o);case 7:return i=t.sent,t.abrupt("return",i.data);case 9:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function ar(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function cr(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var ur=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:60;ar(this,t),this.value=null,this.expirySeconds=e,this.expiryTime=Date.now()}var e,r;return e=t,(r=[{key:"isExpired",value:function(){return null==this.value||Date.now()>this.expiryTime}},{key:"get",value:function(){return this.isExpired()?void 0:this.value}},{key:"set",value:function(t){this.value=t,this.expiryTime=Date.now()+1e3*this.expirySeconds}}])&&cr(e.prototype,r),Object.defineProperty(e,"prototype",{writable:!1}),t}();function sr(t){return sr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},sr(t)}function pr(){return pr="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,r){var n=fr(t,e);if(n){var o=Object.getOwnPropertyDescriptor(n,e);return o.get?o.get.call(arguments.length<3?t:r):o.value}},pr.apply(this,arguments)}function fr(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=dr(t)););return t}function lr(t,e){return lr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},lr(t,e)}function hr(t,e){if(e&&("object"===sr(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}function dr(t){return dr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},dr(t)}function yr(){yr=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,o){var i=e&&e.prototype instanceof l?e:l,a=Object.create(i.prototype),c=new E(o||[]);return n(a,"_invoke",{value:x(t,r,c)}),a}function p(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=s;var f={};function l(){}function h(){}function d(){}var y={};u(y,i,(function(){return this}));var v=Object.getPrototypeOf,g=v&&v(v(T([])));g&&g!==e&&r.call(g,i)&&(y=g);var m=d.prototype=l.prototype=Object.create(y);function w(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function b(t,e){function o(n,i,a,c){var u=p(t[n],t,i);if("throw"!==u.type){var s=u.arg,f=s.value;return f&&"object"==sr(f)&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){s.value=t,a(s)}),(function(t){return o("throw",t,a,c)}))}c(u.arg)}var i;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){o(t,r,e,n)}))}return i=i?i.then(n,n):n()}})}function x(t,e,r){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return{value:void 0,done:!0}}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var c=j(a,r);if(c){if(c===f)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var u=p(t,e,r);if("normal"===u.type){if(n=r.done?"completed":"suspendedYield",u.arg===f)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n="completed",r.method="throw",r.arg=u.arg)}}}function j(t,e){var r=t.iterator[e.method];if(void 0===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=void 0,j(t,e),"throw"===e.method))return f;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var n=p(r,t.iterator,e.arg);if("throw"===n.type)return e.method="throw",e.arg=n.arg,e.delegate=null,f;var o=n.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function L(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function k(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function E(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(L,this),this.reset(!0)}function T(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:S}}function S(){return{value:void 0,done:!0}}return h.prototype=d,n(m,"constructor",{value:d,configurable:!0}),n(d,"constructor",{value:h,configurable:!0}),h.displayName=u(d,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,d):(t.__proto__=d,u(t,c,"GeneratorFunction")),t.prototype=Object.create(m),t},t.awrap=function(t){return{__await:t}},w(b.prototype),u(b.prototype,a,(function(){return this})),t.AsyncIterator=b,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new b(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(m),u(m,c,"Generator"),u(m,i,(function(){return this})),u(m,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=T,E.prototype={constructor:E,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(k),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var c=r.call(i,"catchLoc"),u=r.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:T(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function vr(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function gr(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){vr(i,n,o,a,c,"next",t)}function c(t){vr(i,n,o,a,c,"throw",t)}a(void 0)}))}}function mr(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function wr(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function br(t,e,r){return e&&wr(t.prototype,e),r&&wr(t,r),Object.defineProperty(t,"prototype",{writable:!1}),t}var xr=function(){function t(){mr(this,t),this.apiBaseURL=s.apiBaseURL}var e,r;return br(t,[{key:"getUserDetails",value:(r=gr(yr().mark((function t(){var e,r;return yr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,e={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=6,m.get("".concat(s.apiBaseURL,"/v1/users/me"),e);case 6:return r=t.sent,t.abrupt("return",r.data);case 8:case"end":return t.stop()}}),t)}))),function(){return r.apply(this,arguments)})},{key:"activate",value:(e=gr(yr().mark((function t(e){var r,n;return yr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},n={organizationId:e},t.abrupt("return",m.post("".concat(s.apiBaseURL,"/v1/users/activate"),n,r));case 6:case"end":return t.stop()}}),t)}))),function(t){return e.apply(this,arguments)})}]),t}(),jr=function(){function t(){mr(this,t)}var e,r;return br(t,[{key:"set",value:(r=gr(yr().mark((function t(e){var r,n;return yr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},n={content:e},t.abrupt("return",m.post("".concat(s.apiBaseURL,"/v1/users/me/settings"),n,r));case 6:case"end":return t.stop()}}),t)}))),function(t){return r.apply(this,arguments)})},{key:"get",value:(e=gr(yr().mark((function t(){var e,r;return yr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,e={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=6,m.get("".concat(s.apiBaseURL,"/v1/users/me/settings"),e);case 6:return r=t.sent,t.abrupt("return",r.data.content);case 8:case"end":return t.stop()}}),t)}))),function(){return e.apply(this,arguments)})}]),t}(),Lr=function(t){!function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&lr(t,e)}(a,t);var e,r,n,o,i=(n=a,o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}(),function(){var t,e=dr(n);if(o){var r=dr(this).constructor;t=Reflect.construct(e,arguments,r)}else t=e.apply(this,arguments);return hr(this,t)});function a(){var t,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:300;return mr(this,a),(t=i.call(this,e)).userSettings=new ur(r),t.timerSetUserSettings=null,t}return br(a,[{key:"get",value:(r=gr(yr().mark((function t(){var e;return yr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!(e=this.userSettings.get())){t.next=5;break}return t.abrupt("return",e);case 5:return e=pr(dr(a.prototype),"get",this).call(this),this.userSettings.set(e),t.abrupt("return",e);case 8:case"end":return t.stop()}}),t,this)}))),function(){return r.apply(this,arguments)})},{key:"set",value:(e=gr(yr().mark((function t(e){return yr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return this.userSettings.set(e),t.abrupt("return",pr(dr(a.prototype),"set",this).call(this,e));case 2:case"end":return t.stop()}}),t,this)}))),function(t){return e.apply(this,arguments)})},{key:"setLater",value:function(t){var e=t.data,r=t.afterSeconds,n=void 0===r?10:r,o=this;this.userSettings.set(e),this.timerSetUserSettings&&clearTimeout(this.timerSetUserSettings),this.timerSetUserSettings=setTimeout((function(){o.set(e),o.timerSetUserSettings=null}),1e3*n)}}]),a}(jr);function kr(t){return kr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},kr(t)}function Er(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return Tr(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Tr(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,o=function(){};return{s:o,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,c=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return a=t.done,t},e:function(t){c=!0,i=t},f:function(){try{a||null==r.return||r.return()}finally{if(c)throw i}}}}function Tr(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function Sr(){Sr=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,o){var i=e&&e.prototype instanceof l?e:l,a=Object.create(i.prototype),c=new E(o||[]);return n(a,"_invoke",{value:x(t,r,c)}),a}function p(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=s;var f={};function l(){}function h(){}function d(){}var y={};u(y,i,(function(){return this}));var v=Object.getPrototypeOf,g=v&&v(v(T([])));g&&g!==e&&r.call(g,i)&&(y=g);var m=d.prototype=l.prototype=Object.create(y);function w(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function b(t,e){function o(n,i,a,c){var u=p(t[n],t,i);if("throw"!==u.type){var s=u.arg,f=s.value;return f&&"object"==kr(f)&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){s.value=t,a(s)}),(function(t){return o("throw",t,a,c)}))}c(u.arg)}var i;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){o(t,r,e,n)}))}return i=i?i.then(n,n):n()}})}function x(t,e,r){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return{value:void 0,done:!0}}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var c=j(a,r);if(c){if(c===f)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var u=p(t,e,r);if("normal"===u.type){if(n=r.done?"completed":"suspendedYield",u.arg===f)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n="completed",r.method="throw",r.arg=u.arg)}}}function j(t,e){var r=t.iterator[e.method];if(void 0===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=void 0,j(t,e),"throw"===e.method))return f;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var n=p(r,t.iterator,e.arg);if("throw"===n.type)return e.method="throw",e.arg=n.arg,e.delegate=null,f;var o=n.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function L(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function k(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function E(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(L,this),this.reset(!0)}function T(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:S}}function S(){return{value:void 0,done:!0}}return h.prototype=d,n(m,"constructor",{value:d,configurable:!0}),n(d,"constructor",{value:h,configurable:!0}),h.displayName=u(d,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,d):(t.__proto__=d,u(t,c,"GeneratorFunction")),t.prototype=Object.create(m),t},t.awrap=function(t){return{__await:t}},w(b.prototype),u(b.prototype,a,(function(){return this})),t.AsyncIterator=b,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new b(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(m),u(m,c,"Generator"),u(m,i,(function(){return this})),u(m,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=T,E.prototype={constructor:E,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(k),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var c=r.call(i,"catchLoc"),u=r.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:T(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function Or(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function _r(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){Or(i,n,o,a,c,"next",t)}function c(t){Or(i,n,o,a,c,"throw",t)}a(void 0)}))}}function Ur(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var Pr=function(){function t(e,r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.meetingId=e,this.meetingToken=r}var e,r,n,o,i,a,c;return e=t,r=[{key:"saveImage",value:(c=_r(Sr().mark((function t(e){var r,n,o,i,a;return Sr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:r=e.image,n=(n=e.type)||"",t.t0=n.toLowerCase(),t.next="jpeg"===t.t0?5:"webp"===t.t0?7:9;break;case 5:return n="IMAGE_JPEG",t.abrupt("break",11);case 7:return n="IMAGE_WEBP",t.abrupt("break",11);case 9:return n="",t.abrupt("break",11);case 11:return o={"Content-Type":"image/jpeg",Accept:"application/json","x-jibb-meeting-jwt":this.meetingToken},i={image:r,type:n},t.next=15,m.post("".concat(s.apiBaseURL,"/v1/meetings/").concat(this.meetingId,"/whiteboard/images"),i,o);case 15:return a=t.sent,t.abrupt("return",a.data.imageName);case 17:case"end":return t.stop()}}),t,this)}))),function(t){return c.apply(this,arguments)})},{key:"getImageList",value:function(){var t=_r(Sr().mark((function t(){var e,r;return Sr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e={"Content-Type":"application/json",Accept:"application/json","x-jibb-meeting-jwt":this.meetingToken},t.next=3,m.get("".concat(s.apiBaseURL,"/v1/meetings/").concat(this.meetingId,"/whiteboard/images"),e);case 3:return r=t.sent,t.abrupt("return",r.data.imagesName);case 5:case"end":return t.stop()}}),t,this)})));return function(){return t.apply(this,arguments)}}()},{key:"getImage",value:function(){var t=_r(Sr().mark((function t(e){var r,n,o;return Sr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r={"Content-Type":"application/json",Accept:"image/jpeg","x-jibb-meeting-jwt":this.meetingToken},n="".concat(s.apiBaseURL,"/v1/meetings/").concat(this.meetingId,"/whiteboard/images/").concat(e),t.next=4,m.get(n,r,{responseType:"arraybuffer"});case 4:return o=t.sent,t.abrupt("return",o.data);case 6:case"end":return t.stop()}}),t,this)})));return function(e){return t.apply(this,arguments)}}()},{key:"getImages",value:(a=_r(Sr().mark((function t(){var e,r,n,o,i,a,c;return Sr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e=[],t.next=3,this.getImageList();case 3:r=t.sent,n=Er(r),t.prev=5,n.s();case 7:if((o=n.n()).done){t.next=16;break}return i=o.value,a={"Content-Type":"application/json",Accept:"application/json","x-jibb-meeting-jwt":this.meetingToken},t.next=12,m.get("".concat(s.apiBaseURL,"/v1/meetings/").concat(this.meetingId,"/whiteboard/images/").concat(i),{headers:a});case 12:c=t.sent,e.push({imageName:i,data:c.data});case 14:t.next=7;break;case 16:t.next=21;break;case 18:t.prev=18,t.t0=t.catch(5),n.e(t.t0);case 21:return t.prev=21,n.f(),t.finish(21);case 24:return t.abrupt("return",e);case 25:case"end":return t.stop()}}),t,this,[[5,18,21,24]])}))),function(){return a.apply(this,arguments)})},{key:"deleteImage",value:function(){var t=_r(Sr().mark((function t(e){var r;return Sr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r={"Content-Type":"application/json",Accept:"application/json","x-jibb-meeting-jwt":this.meetingToken},t.abrupt("return",m.delete("".concat(s.apiBaseURL,"/v1/meetings/").concat(this.meetingId,"/whiteboard/images/").concat(e),r));case 2:case"end":return t.stop()}}),t,this)})));return function(e){return t.apply(this,arguments)}}()},{key:"saveBoard",value:(i=_r(Sr().mark((function t(e){var r,n,o;return Sr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r={"Content-Type":"application/json",Accept:"application/json","x-jibb-meeting-jwt":this.meetingToken},n={board:e},t.next=4,m.post("".concat(s.apiBaseURL,"/v1/meetings/").concat(this.meetingId,"/whiteboard"),n,r);case 4:return o=t.sent,t.abrupt("return",o.data);case 6:case"end":return t.stop()}}),t,this)}))),function(t){return i.apply(this,arguments)})},{key:"getBoard",value:(o=_r(Sr().mark((function t(){var e,r;return Sr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e={"Content-Type":"application/json",Accept:"image/jpeg","x-jibb-meeting-jwt":this.meetingToken},t.next=3,m.get("".concat(s.apiBaseURL,"/v1/meetings/").concat(this.meetingId,"/whiteboard"),e);case 3:return r=t.sent,t.abrupt("return",r.data);case 5:case"end":return t.stop()}}),t,this)}))),function(){return o.apply(this,arguments)})},{key:"deleteBoard",value:(n=_r(Sr().mark((function t(){var e;return Sr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e={"Content-Type":"application/json",Accept:"application/json","x-jibb-meeting-jwt":this.meetingToken},t.abrupt("return",m.delete("".concat(s.apiBaseURL,"/v1/meetings/").concat(this.meetingId,"/whiteboard"),e));case 2:case"end":return t.stop()}}),t,this)}))),function(){return n.apply(this,arguments)})}],r&&Ur(e.prototype,r),Object.defineProperty(e,"prototype",{writable:!1}),t}();function Ar(t){return Ar="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ar(t)}function Cr(){Cr=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,o){var i=e&&e.prototype instanceof l?e:l,a=Object.create(i.prototype),c=new E(o||[]);return n(a,"_invoke",{value:x(t,r,c)}),a}function p(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=s;var f={};function l(){}function h(){}function d(){}var y={};u(y,i,(function(){return this}));var v=Object.getPrototypeOf,g=v&&v(v(T([])));g&&g!==e&&r.call(g,i)&&(y=g);var m=d.prototype=l.prototype=Object.create(y);function w(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function b(t,e){function o(n,i,a,c){var u=p(t[n],t,i);if("throw"!==u.type){var s=u.arg,f=s.value;return f&&"object"==Ar(f)&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){s.value=t,a(s)}),(function(t){return o("throw",t,a,c)}))}c(u.arg)}var i;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){o(t,r,e,n)}))}return i=i?i.then(n,n):n()}})}function x(t,e,r){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return{value:void 0,done:!0}}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var c=j(a,r);if(c){if(c===f)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var u=p(t,e,r);if("normal"===u.type){if(n=r.done?"completed":"suspendedYield",u.arg===f)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n="completed",r.method="throw",r.arg=u.arg)}}}function j(t,e){var r=t.iterator[e.method];if(void 0===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=void 0,j(t,e),"throw"===e.method))return f;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var n=p(r,t.iterator,e.arg);if("throw"===n.type)return e.method="throw",e.arg=n.arg,e.delegate=null,f;var o=n.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function L(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function k(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function E(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(L,this),this.reset(!0)}function T(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:S}}function S(){return{value:void 0,done:!0}}return h.prototype=d,n(m,"constructor",{value:d,configurable:!0}),n(d,"constructor",{value:h,configurable:!0}),h.displayName=u(d,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,d):(t.__proto__=d,u(t,c,"GeneratorFunction")),t.prototype=Object.create(m),t},t.awrap=function(t){return{__await:t}},w(b.prototype),u(b.prototype,a,(function(){return this})),t.AsyncIterator=b,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new b(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(m),u(m,c,"Generator"),u(m,i,(function(){return this})),u(m,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=T,E.prototype={constructor:E,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(k),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var c=r.call(i,"catchLoc"),u=r.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:T(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function Rr(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function Ir(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){Rr(i,n,o,a,c,"next",t)}function c(t){Rr(i,n,o,a,c,"throw",t)}a(void 0)}))}}function Nr(t){return Br.apply(this,arguments)}function Br(){return(Br=Ir(Cr().mark((function t(e){var r;return Cr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.t0=m,t.t1="".concat(s.apiBaseURL,"/v1/eventbus/clients/").concat(e,"/cameras"),t.next=4,Vr();case 4:return t.t2=t.sent,t.next=7,t.t0.get.call(t.t0,t.t1,t.t2);case 7:return r=t.sent,t.abrupt("return",r.data.items);case 9:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Gr(t){return Fr.apply(this,arguments)}function Fr(){return(Fr=Ir(Cr().mark((function t(e){var r,n,o,i;return Cr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.cameraId,n=e.clientId,o={source:{id:r}},t.t0=m,t.t1="".concat(s.apiBaseURL,"/v1/eventbus/").concat(n,"/preview"),t.t2=o,t.next=7,Vr();case 7:return t.t3=t.sent,t.next=10,t.t0.post.call(t.t0,t.t1,t.t2,t.t3);case 10:return i=t.sent,t.abrupt("return",i.data.image);case 12:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Dr(t){return zr.apply(this,arguments)}function zr(){return(zr=Ir(Cr().mark((function t(e){var r,n,o,i,a,c,u,p,f,l,h,d,y,v,g;return Cr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(r=e.meetingId,n=e.meetingToken,o=e.surfaceType,i=e.cameraId,a=e.sipUri,c=e.flipLeftRight,u=e.flipUpDown,p=e.rotation,f=e.fixedCorners,l=e.clientId,h=e.customCorners,d=e.enableColor,y=e.enableEstimation,v={config:{surface_type:o},app_config:{meeting_id:r,meeting_token:n},runtime_config:Qr({fixedCorners:f,flipLeftRight:c,flipUpDown:u,rotation:p,customCorners:h,enableColor:d,enableEstimation:y})},i||a){t.next=4;break}return t.abrupt("return",Promise.reject("Invalid request: either sipUri or cameraId should be specified"));case 4:if(!i||!a){t.next=8;break}return t.abrupt("return",Promise.reject("Invalid request: both sipUri (".concat(a,") and cameraId (").concat(a,") are specified")));case 8:a?v.sip_uri=a:v.camera={id:i};case 9:return g={start_request:v},t.t0=m,t.t1="".concat(s.apiBaseURL,"/v1/eventbus/clients/").concat(l,"/start"),t.t2=g,t.next=15,Vr();case 15:return t.t3=t.sent,t.abrupt("return",t.t0.post.call(t.t0,t.t1,t.t2,t.t3));case 17:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Mr(t){return qr.apply(this,arguments)}function qr(){return(qr=Ir(Cr().mark((function t(e){var r;return Cr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r={},t.t0=m,t.t1="".concat(s.apiBaseURL,"/v1/eventbus/").concat(e,"/stop"),t.t2=r,t.next=6,Vr();case 6:return t.t3=t.sent,t.abrupt("return",t.t0.post.call(t.t0,t.t1,t.t2,t.t3));case 8:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Jr(t){return Yr.apply(this,arguments)}function Yr(){return(Yr=Ir(Cr().mark((function t(e){return Cr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.t0=m,t.t1="".concat(s.apiBaseURL,"/v1/eventbus"),t.t2=e,t.next=5,Vr();case 5:return t.t3=t.sent,t.abrupt("return",t.t0.post.call(t.t0,t.t1,t.t2,t.t3));case 7:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Wr(t){return Hr.apply(this,arguments)}function Hr(){return(Hr=Ir(Cr().mark((function t(e){var r,n,o,i,a,c,u,p,f;return Cr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.flipLeftRight,n=e.flipUpDown,o=e.rotation,i=e.fixedCorners,a=e.customCorners,c=e.clientId,u=e.enableColor,p=e.enableEstimation,f={runtime_config_request:{runtime_config:Qr({fixedCorners:i,flipLeftRight:r,flipUpDown:n,rotation:o,customCorners:a,enableColor:u,enableEstimation:p})}},t.t0=m,t.t1="".concat(s.apiBaseURL,"/v1/eventbus/").concat(c,"/runtime_config"),t.t2=f,t.next=7,Vr();case 7:return t.t3=t.sent,t.abrupt("return",t.t0.post.call(t.t0,t.t1,t.t2,t.t3));case 9:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Kr(){return $r.apply(this,arguments)}function $r(){return($r=Ir(Cr().mark((function t(){var e;return Cr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.t0=m,t.t1="".concat(s.apiBaseURL,"/v1/eventbus/clients"),t.next=4,Vr();case 4:return t.t2=t.sent,t.next=7,t.t0.get.call(t.t0,t.t1,t.t2);case 7:return e=t.sent,t.abrupt("return",e.data.clients);case 9:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Vr(){return Xr.apply(this,arguments)}function Xr(){return(Xr=Ir(Cr().mark((function t(){return Cr().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,t.abrupt("return",{"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0});case 4:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Qr(t){var e=t.fixedCorners,r=t.flipLeftRight,n=t.flipUpDown,o=t.rotation,i=t.customCorners,a=t.enableColor,c=t.enableEstimation;switch(o){case 90:o="1";break;case 180:case-180:o="2";break;case-90:case 270:o="3";break;default:o="0"}return{custom_corners:i||[],rotation:o,enable_color:a||!1,fixed_corners:e,enable_estimation:c||!1,flip_up_down:n||!1,flip_left_right:r||!1}}function Zr(t){return Zr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Zr(t)}function tn(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return en(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?en(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,o=function(){};return{s:o,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,c=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return a=t.done,t},e:function(t){c=!0,i=t},f:function(){try{a||null==r.return||r.return()}finally{if(c)throw i}}}}function en(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function rn(){rn=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",c=o.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function s(t,e,r,o){var i=e&&e.prototype instanceof l?e:l,a=Object.create(i.prototype),c=new E(o||[]);return n(a,"_invoke",{value:x(t,r,c)}),a}function p(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=s;var f={};function l(){}function h(){}function d(){}var y={};u(y,i,(function(){return this}));var v=Object.getPrototypeOf,g=v&&v(v(T([])));g&&g!==e&&r.call(g,i)&&(y=g);var m=d.prototype=l.prototype=Object.create(y);function w(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function b(t,e){function o(n,i,a,c){var u=p(t[n],t,i);if("throw"!==u.type){var s=u.arg,f=s.value;return f&&"object"==Zr(f)&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){o("next",t,a,c)}),(function(t){o("throw",t,a,c)})):e.resolve(f).then((function(t){s.value=t,a(s)}),(function(t){return o("throw",t,a,c)}))}c(u.arg)}var i;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){o(t,r,e,n)}))}return i=i?i.then(n,n):n()}})}function x(t,e,r){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return{value:void 0,done:!0}}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var c=j(a,r);if(c){if(c===f)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var u=p(t,e,r);if("normal"===u.type){if(n=r.done?"completed":"suspendedYield",u.arg===f)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n="completed",r.method="throw",r.arg=u.arg)}}}function j(t,e){var r=t.iterator[e.method];if(void 0===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=void 0,j(t,e),"throw"===e.method))return f;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var n=p(r,t.iterator,e.arg);if("throw"===n.type)return e.method="throw",e.arg=n.arg,e.delegate=null,f;var o=n.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function L(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function k(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function E(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(L,this),this.reset(!0)}function T(t){if(t){var e=t[i];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:S}}function S(){return{value:void 0,done:!0}}return h.prototype=d,n(m,"constructor",{value:d,configurable:!0}),n(d,"constructor",{value:h,configurable:!0}),h.displayName=u(d,c,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===h||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,d):(t.__proto__=d,u(t,c,"GeneratorFunction")),t.prototype=Object.create(m),t},t.awrap=function(t){return{__await:t}},w(b.prototype),u(b.prototype,a,(function(){return this})),t.AsyncIterator=b,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new b(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(m),u(m,c,"Generator"),u(m,i,(function(){return this})),u(m,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=T,E.prototype={constructor:E,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(k),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return n("end");if(i.tryLoc<=this.prev){var c=r.call(i,"catchLoc"),u=r.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return n(i.catchLoc,!0);if(this.prev<i.finallyLoc)return n(i.finallyLoc)}else if(c){if(this.prev<i.catchLoc)return n(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return n(i.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),k(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;k(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:T(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function nn(t,e,r,n,o,i,a){try{var c=t[i](a),u=c.value}catch(t){return void r(t)}c.done?e(u):Promise.resolve(u).then(n,o)}function on(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){nn(i,n,o,a,c,"next",t)}function c(t){nn(i,n,o,a,c,"throw",t)}a(void 0)}))}}function an(t){return cn.apply(this,arguments)}function cn(){return(cn=on(rn().mark((function t(e){var r,n,o,i;return rn().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.recordingId,n=e.title,t.next=3,ct.getUserToken();case 3:return t.t0=t.sent,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},i={title:n},t.abrupt("return",m.post("".concat(s.apiBaseURL,"/v1/meetings/recordings/").concat(r),i,o));case 7:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function un(t){return sn.apply(this,arguments)}function sn(){return(sn=on(rn().mark((function t(e){var r,n;return rn().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=6,m.get("".concat(s.apiBaseURL,"/v1/meetings/recordings/").concat(e),r);case 6:return n=t.sent,t.abrupt("return",n.data);case 8:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function pn(t){return fn.apply(this,arguments)}function fn(){return(fn=on(rn().mark((function t(e){var r,n;return rn().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},void 0!==e&&(r["x-jibb-pagination"]=JSON.stringify(e)),t.next=7,m.get("".concat(s.apiBaseURL,"/v1/meetings/recordings"),r);case 7:return n=t.sent,e=(e=n.headers["x-jibb-pagination"])&&JSON.parse(e),t.abrupt("return",{items:n.data.items,pagination:e});case 11:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function ln(t){return hn.apply(this,arguments)}function hn(){return(hn=on(rn().mark((function t(e){var r;return rn().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.abrupt("return",m.delete("".concat(s.apiBaseURL,"/v1/meetings/recordings/").concat(e),r));case 5:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function dn(t){return yn.apply(this,arguments)}function yn(){return(yn=on(rn().mark((function t(e){var r,n;return rn().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,r={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=6,m.get("".concat(s.apiBaseURL,"/v1/meetings/recordings/").concat(e,"/images"),r);case 6:return n=t.sent,t.abrupt("return",n.data.imageName);case 8:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function vn(t){return gn.apply(this,arguments)}function gn(){return(gn=on(rn().mark((function t(e){var r,n,o,i,a;return rn().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.recordingId,n=e.imageName,t.next=3,ct.getUserToken();case 3:return t.t0=t.sent,o={"Content-Type":"application/json",Accept:"image/jpeg","x-jibb-user-jwt":t.t0},i="".concat(s.apiBaseURL,"/v1/meetings/recordings/").concat(r,"/images/").concat(n),t.next=8,m.get(i,o,{responseType:"arraybuffer"});case 8:return a=t.sent,t.abrupt("return",a.data);case 10:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function mn(t){return wn.apply(this,arguments)}function wn(){return(wn=on(rn().mark((function t(e){var r,n,o,i,a,c,u;return rn().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=[],t.next=3,this.getImageList(e);case 3:n=t.sent,o=tn(n),t.prev=5,o.s();case 7:if((i=o.n()).done){t.next=19;break}return a=i.value,t.next=11,ct.getUserToken();case 11:return t.t0=t.sent,c={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.next=15,m.get("".concat(s.apiBaseURL,"/v1/meetings/recordings/").concat(e,"/images/").concat(a),{headers:c});case 15:u=t.sent,r.push({imageName:a,data:u.data});case 17:t.next=7;break;case 19:t.next=24;break;case 21:t.prev=21,t.t1=t.catch(5),o.e(t.t1);case 24:return t.prev=24,o.f(),t.finish(24);case 27:return t.abrupt("return",r);case 28:case"end":return t.stop()}}),t,this,[[5,21,24,27]])})))).apply(this,arguments)}function bn(t){return xn.apply(this,arguments)}function xn(){return(xn=on(rn().mark((function t(e){var r,n,o;return rn().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.recordingId,n=e.imageName,t.next=3,ct.getUserToken();case 3:return t.t0=t.sent,o={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},t.abrupt("return",m.delete("".concat(s.apiBaseURL,"/v1/meetings/recordings/").concat(r,"/images/").concat(n),o));case 6:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function jn(){return Ln.apply(this,arguments)}function Ln(){return Ln=on(rn().mark((function t(){var e,r=arguments;return rn().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e=r.length>0&&void 0!==r[0]?r[0]:{meetingId,meetingToken,title:"UNTITLED",interval:60},t.abrupt("return",on(rn().mark((function t(){var r,n,o,i,a,c,u;return rn().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=null==e?void 0:e.meetingToken,n=(null==e?void 0:e.title)||"UNTITLED",o=(null==e?void 0:e.interval)||60,i=null==e?void 0:e.meetingId,t.next=6,ct.getUserToken();case 6:return t.t0=t.sent,t.t1=r,a={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0,"x-jibb-meeting-jwt":t.t1},c={title:n,write_interval:o,meeting_id:i},t.next=12,m.post("".concat(s.apiBaseURL,"/v1/meetings/recordings/start"),c,a);case 12:return u=t.sent,t.abrupt("return",u.data);case 14:case"end":return t.stop()}}),t)})))());case 2:case"end":return t.stop()}}),t)}))),Ln.apply(this,arguments)}function kn(){return En.apply(this,arguments)}function En(){return(En=on(rn().mark((function t(){var e,r,n;return rn().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,e={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},r={},t.next=7,m.post("".concat(s.apiBaseURL,"/v1/meetings/recordings/stop"),r,e);case 7:return n=t.sent,t.abrupt("return",n.data);case 9:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Tn(){return Sn.apply(this,arguments)}function Sn(){return(Sn=on(rn().mark((function t(){var e,r,n;return rn().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,ct.getUserToken();case 2:return t.t0=t.sent,e={"Content-Type":"application/json",Accept:"application/json","x-jibb-user-jwt":t.t0},r={},t.next=7,m.post("".concat(s.apiBaseURL,"/v1/meetings/recordings/snapshot"),r,e);case 7:return n=t.sent,t.abrupt("return",n.data);case 9:case"end":return t.stop()}}),t)})))).apply(this,arguments)}o.e(462).then(o.bind(o,462)).then((function(t){T=t.logger}));const On={WebexBot:t,Meeting:e,Auth:ct,User:xr,Admin:n,SuperAdmin:r,Recording:c,Whiteboard:Pr,Settings:jr,CachedSettings:Lr,EventBus:a}})(),i.default})()));
|
|
@@ -1,112 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
* <h2>Browser start session example.</h2>
|
|
5
|
-
*
|
|
6
|
-
* <ul style="list-style: none;">
|
|
7
|
-
* <li> Click on source to see the script example.
|
|
8
|
-
* <li> Check the html example below for full example were jibb.js is the sdk.
|
|
9
|
-
* </ul>
|
|
10
|
-
*
|
|
11
|
-
* @example
|
|
12
|
-
* <!DOCTYPE html>
|
|
13
|
-
* <html>
|
|
14
|
-
* <body>
|
|
15
|
-
*
|
|
16
|
-
* <h1>The script testing start session</h1>
|
|
17
|
-
* <script type="module">
|
|
18
|
-
* import * as JIBB from './jibb.js'
|
|
19
|
-
* </script>
|
|
20
|
-
* <script type="module" src="startSession.js">
|
|
21
|
-
* </script>
|
|
22
|
-
*
|
|
23
|
-
* </body>
|
|
24
|
-
* </html>
|
|
25
|
-
* @name Browser Start Session
|
|
26
|
-
* @memberof Examples
|
|
27
|
-
*
|
|
28
|
-
*/
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
let MeetingAPI = JIBB.Meeting
|
|
34
|
-
let Auth = JIBB.Auth
|
|
35
|
-
let EventBus = JIBB.EventBus
|
|
36
|
-
|
|
37
|
-
const SurfaceType = {
|
|
38
|
-
PAPER: "PAPER",
|
|
39
|
-
WHITEBOARD: "WHITEBOARD",
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
function Config(apiKey) {
|
|
43
|
-
this.apiKey = apiKey
|
|
44
|
-
this.webURL = "https://app.jibb.ai"
|
|
45
|
-
|
|
46
|
-
Auth.setApiKey(this.apiKey)
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
var meetingId = ""
|
|
50
|
-
|
|
51
|
-
function sleep(ms) {
|
|
52
|
-
return new Promise((resolve) => setTimeout(resolve, ms))
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
function openInNewTab(url) {
|
|
56
|
-
console.log("openInNewTab ...")
|
|
57
|
-
// needs to be opened in a different app so that the script continue, browser might stop popup for this example, click allow popup.
|
|
58
|
-
window.open(url, "_blank")
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
async function generateMeetingLink() {
|
|
62
|
-
console.log("generating meeting link ...")
|
|
63
|
-
|
|
64
|
-
let userToken = await Auth.getUserToken()
|
|
65
|
-
|
|
66
|
-
let title = "start Session example"
|
|
67
|
-
|
|
68
|
-
meetingId = await MeetingAPI.createMeeting({ title: title, isTemporary: true })
|
|
69
|
-
|
|
70
|
-
let url = `${config.webURL}/remote/${meetingId}?user_token=${userToken}`
|
|
71
|
-
return url
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
async function StartMeeting() {
|
|
75
|
-
console.log("StartMeeting ...")
|
|
76
|
-
|
|
77
|
-
let url = await generateMeetingLink()
|
|
78
|
-
openInNewTab(url)
|
|
79
|
-
// waiting for browser to open the URL, next calls needs to be done after the link is opened
|
|
80
|
-
await sleep(10000)
|
|
81
|
-
|
|
82
|
-
// getting the opened browser client ID
|
|
83
|
-
let statusList = await EventBus.getClientStatusList()
|
|
84
|
-
let clinetID = statusList[0].id
|
|
85
|
-
|
|
86
|
-
// asking the browser for the availble camera Ids, make sure camera access is already allowed.
|
|
87
|
-
let cameraList = await EventBus.getCameraList(clinetID)
|
|
88
|
-
|
|
89
|
-
if (cameraList.length) {
|
|
90
|
-
//preparing the startstream request
|
|
91
|
-
// getting meeting token, required for any meeting related requests.
|
|
92
|
-
let meetingToken = await MeetingAPI.getMeetingToken({ meetingId: meetingId, permission: 2 })
|
|
93
|
-
let surfaceType = SurfaceType.WHITEBOARD
|
|
94
|
-
//choose desired camera
|
|
95
|
-
let cameraId = cameraList[1].id
|
|
96
|
-
let req = {
|
|
97
|
-
meetingId: meetingId,
|
|
98
|
-
meetingToken: meetingToken,
|
|
99
|
-
surfaceType: surfaceType,
|
|
100
|
-
cameraId: cameraId,
|
|
101
|
-
clientId: clinetID,
|
|
102
|
-
}
|
|
103
|
-
await EventBus.startStream(req)
|
|
104
|
-
} else return Promise.reject("No Camera Access")
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
async function main() {
|
|
108
|
-
StartMeeting()
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
let config = new Config("a2ec50bc-76cf-4d4c-8b54-b6b664f3815c")
|
|
112
|
-
main()
|