1 // *************************************************************************
3 // * xCALLY Motion - The Omnichannel Contact Center *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved *
6 // *************************************************************************
8 // * Email: info@xcally.com *
9 // * Website: https://www.xcally.com *
11 // *************************************************************************
13 // * The SOFTWARE PRODUCT is protected by copyright laws and international *
14 // * copyright treaties, as well as other intellectual property laws and *
15 // * treaties. The SOFTWARE PRODUCT is licensed, not sold. *
17 // *************************************************************************
18 var _0xc52f=['./rpc/user','./rpc/interval','./rpc/openchannelQueue','./rpc/smsQueue','./rpc/mailQueue','./rpc/faxQueue','./rpc/whatsappQueue','resolve','then','getAgents','initAgents','getIntervals','getOpenchannelQueues','initOpenchannelQueues','initChatQueues','initSmsQueues','getMailQueues','initMailQueues','getFaxQueues','initFaxQueues','getWhatsappQueues','initWhatsappQueues','listen','catch','./server'];(function(_0x35ce5b,_0x298b5c){var _0x3a9266=function(_0x1326b5){while(--_0x1326b5){_0x35ce5b['push'](_0x35ce5b['shift']());}};_0x3a9266(++_0x298b5c);}(_0xc52f,0xae));var _0xfc52=function(_0x15e128,_0x83f28){_0x15e128=_0x15e128-0x0;var _0x57da7a=_0xc52f[_0x15e128];return _0x57da7a;};'use strict';var BPromise=require('bluebird');var server=require(_0xfc52('0x0'));var Realtime=require('./realtime');var user=require(_0xfc52('0x1'));var interval=require(_0xfc52('0x2'));var openchannelQueue=require(_0xfc52('0x3'));var chatQueue=require('./rpc/chatQueue');var smsQueue=require(_0xfc52('0x4'));var mailQueue=require(_0xfc52('0x5'));var faxQueue=require(_0xfc52('0x6'));var whatsappQueue=require(_0xfc52('0x7'));var realtime=new Realtime();function initRealtime(){return BPromise[_0xfc52('0x8')]()[_0xfc52('0x9')](user[_0xfc52('0xa')]())[_0xfc52('0x9')](realtime[_0xfc52('0xb')]())[_0xfc52('0x9')](interval[_0xfc52('0xc')]())[_0xfc52('0x9')](realtime['initIntervals']())['then'](openchannelQueue[_0xfc52('0xd')]())[_0xfc52('0x9')](realtime[_0xfc52('0xe')]())[_0xfc52('0x9')](chatQueue['getChatQueues']())[_0xfc52('0x9')](realtime[_0xfc52('0xf')]())[_0xfc52('0x9')](smsQueue['getSmsQueues']())[_0xfc52('0x9')](realtime[_0xfc52('0x10')]())[_0xfc52('0x9')](mailQueue[_0xfc52('0x11')]())[_0xfc52('0x9')](realtime[_0xfc52('0x12')]())[_0xfc52('0x9')](faxQueue[_0xfc52('0x13')]())[_0xfc52('0x9')](realtime[_0xfc52('0x14')]())[_0xfc52('0x9')](whatsappQueue[_0xfc52('0x15')]())[_0xfc52('0x9')](realtime[_0xfc52('0x16')]())[_0xfc52('0x9')](function(){return realtime;});}function main(){return server[_0xfc52('0x17')](realtime)[_0xfc52('0x9')](function(_0x1d42c7){return initRealtime();})[_0xfc52('0x9')](function(_0x52d697){return setInterval(initRealtime,0x1388);})[_0xfc52('0x18')](function(_0x4b6302){console['log'](_0x4b6302);});}main();