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 _0xb6b1=['FreshsalesConfiguration','Configurations','Subjects','content','Variable','FreshsalesField','key','keyType','keyContent','variableName','GetFreshsalesccount','../../client','GetFreshsalesAccount','name','apiKey','serverUrl'];(function(_0x37ab1e,_0x24db8c){var _0x192910=function(_0x42ad2c){while(--_0x42ad2c){_0x37ab1e['push'](_0x37ab1e['shift']());}};_0x192910(++_0x24db8c);}(_0xb6b1,0x17b));var _0x1b6b=function(_0x4c7d8b,_0x572388){_0x4c7d8b=_0x4c7d8b-0x0;var _0x187158=_0xb6b1[_0x4c7d8b];return _0x187158;};'use strict';var client=require(_0x1b6b('0x0'));exports['getFreshsalesAccounts']=function(){return function(_0x669faa){return client['Request'](_0x1b6b('0x1'),{'options':{'raw':![],'attributes':['id',_0x1b6b('0x2'),'username',_0x1b6b('0x3'),'remoteUri',_0x1b6b('0x4')],'include':[{'model':_0x1b6b('0x5'),'as':_0x1b6b('0x6'),'attributes':['id',_0x1b6b('0x2')],'include':[{'model':'FreshsalesField','as':_0x1b6b('0x7'),'attributes':['id','type',_0x1b6b('0x8'),'variableName'],'include':[{'model':_0x1b6b('0x9'),'as':_0x1b6b('0x9'),'attributes':['id',_0x1b6b('0x2')]}]},{'model':_0x1b6b('0xa'),'as':'Descriptions','attributes':['id','type',_0x1b6b('0x8'),_0x1b6b('0xb'),_0x1b6b('0xc'),_0x1b6b('0xd'),_0x1b6b('0xe')],'include':[{'model':_0x1b6b('0x9'),'as':_0x1b6b('0x9'),'attributes':['id','name']}]}]}]},'log':_0x1b6b('0xf')});};};