0fa4ee8b16efa49c2032595078e3becbcb42c598
[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 _0x9f5a=['keyType','GetFreshsalesccount','../../client','getFreshsalesAccounts','Request','name','username','apiKey','serverUrl','Configurations','Subjects','type','content','variableName','Variable','Descriptions','key'];(function(_0x56cd9e,_0x1343b6){var _0x22b0e2=function(_0x361090){while(--_0x361090){_0x56cd9e['push'](_0x56cd9e['shift']());}};_0x22b0e2(++_0x1343b6);}(_0x9f5a,0xbd));var _0xa9f5=function(_0x28dca2,_0x42d7f5){_0x28dca2=_0x28dca2-0x0;var _0xd440f=_0x9f5a[_0x28dca2];return _0xd440f;};'use strict';var client=require(_0xa9f5('0x0'));exports[_0xa9f5('0x1')]=function(){return function(_0x218f89){return client[_0xa9f5('0x2')]('GetFreshsalesAccount',{'options':{'raw':![],'attributes':['id',_0xa9f5('0x3'),_0xa9f5('0x4'),_0xa9f5('0x5'),'remoteUri',_0xa9f5('0x6')],'include':[{'model':'FreshsalesConfiguration','as':_0xa9f5('0x7'),'attributes':['id',_0xa9f5('0x3')],'include':[{'model':'FreshsalesField','as':_0xa9f5('0x8'),'attributes':['id',_0xa9f5('0x9'),_0xa9f5('0xa'),_0xa9f5('0xb')],'include':[{'model':_0xa9f5('0xc'),'as':_0xa9f5('0xc'),'attributes':['id',_0xa9f5('0x3')]}]},{'model':'FreshsalesField','as':_0xa9f5('0xd'),'attributes':['id',_0xa9f5('0x9'),'content',_0xa9f5('0xe'),_0xa9f5('0xf'),'keyContent','variableName'],'include':[{'model':_0xa9f5('0xc'),'as':_0xa9f5('0xc'),'attributes':['id',_0xa9f5('0x3')]}]}]}]},'log':_0xa9f5('0x10')});};};