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 _0xc737=['sendMailMessage','SendMail','bluebird','jayson/promise','client','http','request','then','error','message'];(function(_0x2b9dc4,_0x5baa42){var _0x236b8a=function(_0x2501d3){while(--_0x2501d3){_0x2b9dc4['push'](_0x2b9dc4['shift']());}};_0x236b8a(++_0x5baa42);}(_0xc737,0x160));var _0x7c73=function(_0x2c2df9,_0x3550b7){_0x2c2df9=_0x2c2df9-0x0;var _0x51e9b7=_0xc737[_0x2c2df9];return _0x51e9b7;};'use strict';var BPromise=require(_0x7c73('0x0'));var jayson=require(_0x7c73('0x1'));var client=jayson[_0x7c73('0x2')][_0x7c73('0x3')]({'port':0x232b});function request(_0xcfd33b,_0x1f9f59){return new BPromise(function(_0x35e1b8,_0x21f734){return client[_0x7c73('0x4')](_0xcfd33b,_0x1f9f59)[_0x7c73('0x5')](function(_0x5bf1b1){if(_0x5bf1b1[_0x7c73('0x6')]){return _0x21f734(_0x5bf1b1[_0x7c73('0x6')][_0x7c73('0x7')]);}else{return _0x35e1b8(_0x5bf1b1['result']);}})['catch'](function(_0x447531){return _0x21f734(_0x447531);});});}exports[_0x7c73('0x8')]=function(_0x1cd8d5,_0x264f6f){return request(_0x7c73('0x9'),{'account':_0x1cd8d5,'message':_0x264f6f});};