e0bdb0916ef88ae0f412629fb88559e7b6cba3f3
[motion2.git] / server / services / ami / rpc / integrations / freshsales.js
1 // *************************************************************************
2 // *                                                                       *
3 // * xCALLY Motion -  The Omnichannel Contact Center                       *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved                     *
5 // *                                                                       *
6 // *************************************************************************
7 // *                                                                       *
8 // * Email: info@xcally.com                                                *
9 // * Website: https://www.xcally.com                                       *
10 // *                                                                       *
11 // *************************************************************************
12 // *                                                                       *
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.                         *
16 // *                                                                       *
17 // *************************************************************************
18 var _0x79d8=['Request','name','username','remoteUri','serverUrl','FreshsalesConfiguration','FreshsalesField','Subjects','type','variableName','Variable','keyType','keyContent','../../client','getFreshsalesAccounts'];(function(_0x451e1e,_0x123d75){var _0x4cfd6e=function(_0x188a4c){while(--_0x188a4c){_0x451e1e['push'](_0x451e1e['shift']());}};_0x4cfd6e(++_0x123d75);}(_0x79d8,0x67));var _0x879d=function(_0x54912f,_0xab2f7d){_0x54912f=_0x54912f-0x0;var _0x1ca99a=_0x79d8[_0x54912f];return _0x1ca99a;};'use strict';var client=require(_0x879d('0x0'));exports[_0x879d('0x1')]=function(){return function(_0xc4fa1e){return client[_0x879d('0x2')]('GetFreshsalesAccount',{'options':{'raw':![],'attributes':['id',_0x879d('0x3'),_0x879d('0x4'),'apiKey',_0x879d('0x5'),_0x879d('0x6')],'include':[{'model':_0x879d('0x7'),'as':'Configurations','attributes':['id',_0x879d('0x3')],'include':[{'model':_0x879d('0x8'),'as':_0x879d('0x9'),'attributes':['id',_0x879d('0xa'),'content',_0x879d('0xb')],'include':[{'model':_0x879d('0xc'),'as':_0x879d('0xc'),'attributes':['id',_0x879d('0x3')]}]},{'model':_0x879d('0x8'),'as':'Descriptions','attributes':['id',_0x879d('0xa'),'content','key',_0x879d('0xd'),_0x879d('0xe'),_0x879d('0xb')],'include':[{'model':'Variable','as':_0x879d('0xc'),'attributes':['id',_0x879d('0x3')]}]}]}]},'log':'GetFreshsalesccount'});};};