6f6c6ae50e9d563db081847a2f05946af1b581c3
[motion2.git] / server / services / ami / rpc / integrations / salesforce.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 _0x0810=['clientId','clientSecret','securityToken','serverUrl','type','SalesforceConfiguration','Configurations','SalesforceField','Variable','Descriptions','GetSalesforceAccount','name','username','remoteUri'];(function(_0x468b0f,_0x408566){var _0x3e74d9=function(_0x27a545){while(--_0x27a545){_0x468b0f['push'](_0x468b0f['shift']());}};_0x3e74d9(++_0x408566);}(_0x0810,0x1e6));var _0x0081=function(_0x2ab1c9,_0x381531){_0x2ab1c9=_0x2ab1c9-0x0;var _0x48d74d=_0x0810[_0x2ab1c9];return _0x48d74d;};'use strict';var client=require('../../client');exports['getSalesforceAccounts']=function(){return function(_0x1f8798){return client['Request'](_0x0081('0x0'),{'options':{'raw':![],'attributes':['id',_0x0081('0x1'),_0x0081('0x2'),'password',_0x0081('0x3'),_0x0081('0x4'),_0x0081('0x5'),_0x0081('0x6'),_0x0081('0x7'),_0x0081('0x8')],'include':[{'model':_0x0081('0x9'),'as':_0x0081('0xa'),'attributes':['id',_0x0081('0x1'),'moduleSearch','moduleCreate','ticketType'],'include':[{'model':_0x0081('0xb'),'as':'Subjects','include':[{'model':_0x0081('0xc'),'as':'Variable','attributes':['id',_0x0081('0x1')]}]},{'model':_0x0081('0xb'),'as':_0x0081('0xd'),'include':[{'model':'Variable','as':_0x0081('0xc'),'attributes':['id',_0x0081('0x1')]}]},{'model':_0x0081('0xb'),'as':'Fields','include':[{'model':_0x0081('0xc'),'as':'Variable','attributes':['id','name']}]}]}]},'log':'GetSalesforceAccount'});};};