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 _0x20e7=['bluebird','client','http','request','then','error','catch','sendMailMessage','SendMail'];(function(_0x39ad1c,_0x3ed5c5){var _0x214fa8=function(_0x5ad3a3){while(--_0x5ad3a3){_0x39ad1c['push'](_0x39ad1c['shift']());}};_0x214fa8(++_0x3ed5c5);}(_0x20e7,0x195));var _0x720e=function(_0x410069,_0x18b3d1){_0x410069=_0x410069-0x0;var _0x1ab235=_0x20e7[_0x410069];return _0x1ab235;};'use strict';var BPromise=require(_0x720e('0x0'));var jayson=require('jayson/promise');var client=jayson[_0x720e('0x1')][_0x720e('0x2')]({'port':0x232b});function request(_0x58c50f,_0x37f92d){return new BPromise(function(_0x2de182,_0x7f7ba2){return client[_0x720e('0x3')](_0x58c50f,_0x37f92d)[_0x720e('0x4')](function(_0x52e68f){if(_0x52e68f[_0x720e('0x5')]){return _0x7f7ba2(_0x52e68f['error']['message']);}else{return _0x2de182(_0x52e68f['result']);}})[_0x720e('0x6')](function(_0x1044a1){return _0x7f7ba2(_0x1044a1);});});}exports[_0x720e('0x7')]=function(_0x4d1d15,_0xe8b6b4){return request(_0x720e('0x8'),{'account':_0x4d1d15,'message':_0xe8b6b4});};