231ed9ac61824c56d01fc1466a341e0abd043361
[motion2.git] / server / services / ami / rpc / integrations / freshdesk.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 _0x54a0=['Fields','idField','nameField','Request','GetFreshdeskAccount','username','apiKey','remoteUri','serverUrl','Configurations','Tag','name','FreshdeskField','Subjects','type','content','variableName','Variable','Descriptions','key','keyType','keyContent'];(function(_0x3dd15e,_0x1f0015){var _0x231fd0=function(_0x4f680a){while(--_0x4f680a){_0x3dd15e['push'](_0x3dd15e['shift']());}};_0x231fd0(++_0x1f0015);}(_0x54a0,0x1e7));var _0x054a=function(_0x4a73bd,_0x143f97){_0x4a73bd=_0x4a73bd-0x0;var _0x1b0427=_0x54a0[_0x4a73bd];return _0x1b0427;};'use strict';var client=require('../../client');exports['getFreshdeskAccounts']=function(){return function(_0x128c35){return client[_0x054a('0x0')](_0x054a('0x1'),{'options':{'raw':![],'attributes':['id','name',_0x054a('0x2'),_0x054a('0x3'),_0x054a('0x4'),_0x054a('0x5')],'include':[{'model':'FreshdeskConfiguration','as':_0x054a('0x6'),'attributes':['id','name'],'include':[{'model':_0x054a('0x7'),'attributes':['id',_0x054a('0x8')]},{'model':_0x054a('0x9'),'as':_0x054a('0xa'),'attributes':['id',_0x054a('0xb'),_0x054a('0xc'),_0x054a('0xd')],'include':[{'model':_0x054a('0xe'),'as':'Variable','attributes':['id',_0x054a('0x8')]}]},{'model':_0x054a('0x9'),'as':_0x054a('0xf'),'attributes':['id',_0x054a('0xb'),_0x054a('0xc'),_0x054a('0x10'),_0x054a('0x11'),_0x054a('0x12'),_0x054a('0xd')],'include':[{'model':_0x054a('0xe'),'as':'Variable','attributes':['id','name']}]},{'model':_0x054a('0x9'),'as':_0x054a('0x13'),'attributes':['id','type',_0x054a('0xc'),_0x054a('0x14'),_0x054a('0x15'),'customField',_0x054a('0xd')],'include':[{'model':_0x054a('0xe'),'as':_0x054a('0xe'),'attributes':['id',_0x054a('0x8')]}]}]}]},'log':'GetFreshdeskAccount'});};};