Built motion from commit (unavailable).|2.5.0
[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 _0xf972=['serverUrl','FreshsalesConfiguration','Configurations','name','FreshsalesField','Subjects','type','content','variableName','Descriptions','keyContent','Variable','../../client','Request','GetFreshsalesAccount','username','apiKey'];(function(_0x555ebb,_0x4b1b68){var _0x3c0a4a=function(_0x312e2f){while(--_0x312e2f){_0x555ebb['push'](_0x555ebb['shift']());}};_0x3c0a4a(++_0x4b1b68);}(_0xf972,0x171));var _0x2f97=function(_0x26b68c,_0x389f20){_0x26b68c=_0x26b68c-0x0;var _0x4e772a=_0xf972[_0x26b68c];return _0x4e772a;};'use strict';var client=require(_0x2f97('0x0'));exports['getFreshsalesAccounts']=function(){return function(_0x119361){return client[_0x2f97('0x1')](_0x2f97('0x2'),{'options':{'raw':![],'attributes':['id','name',_0x2f97('0x3'),_0x2f97('0x4'),'remoteUri',_0x2f97('0x5')],'include':[{'model':_0x2f97('0x6'),'as':_0x2f97('0x7'),'attributes':['id',_0x2f97('0x8')],'include':[{'model':_0x2f97('0x9'),'as':_0x2f97('0xa'),'attributes':['id',_0x2f97('0xb'),_0x2f97('0xc'),_0x2f97('0xd')],'include':[{'model':'Variable','as':'Variable','attributes':['id',_0x2f97('0x8')]}]},{'model':_0x2f97('0x9'),'as':_0x2f97('0xe'),'attributes':['id','type',_0x2f97('0xc'),'key','keyType',_0x2f97('0xf'),_0x2f97('0xd')],'include':[{'model':_0x2f97('0x10'),'as':_0x2f97('0x10'),'attributes':['id',_0x2f97('0x8')]}]}]}]},'log':'GetFreshsalesccount'});};};