45594344b3a0a8632c128959b956b7568c1e5d69
[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 _0x85c7=['Request','name','username','apiKey','serverUrl','FreshdeskConfiguration','Configurations','Tag','FreshdeskField','content','variableName','Variable','type','key','keyType','keyContent','Fields','idField','nameField','customField','GetFreshdeskAccount','../../client'];(function(_0x5de116,_0x49884e){var _0x53958b=function(_0x1297a4){while(--_0x1297a4){_0x5de116['push'](_0x5de116['shift']());}};_0x53958b(++_0x49884e);}(_0x85c7,0x1a1));var _0x785c=function(_0x618414,_0x1a7a60){_0x618414=_0x618414-0x0;var _0x21c19a=_0x85c7[_0x618414];return _0x21c19a;};'use strict';var client=require(_0x785c('0x0'));exports['getFreshdeskAccounts']=function(){return function(_0x4a0847){return client[_0x785c('0x1')]('GetFreshdeskAccount',{'options':{'raw':![],'attributes':['id',_0x785c('0x2'),_0x785c('0x3'),_0x785c('0x4'),'remoteUri',_0x785c('0x5')],'include':[{'model':_0x785c('0x6'),'as':_0x785c('0x7'),'attributes':['id',_0x785c('0x2')],'include':[{'model':_0x785c('0x8'),'attributes':['id',_0x785c('0x2')]},{'model':_0x785c('0x9'),'as':'Subjects','attributes':['id','type',_0x785c('0xa'),_0x785c('0xb')],'include':[{'model':_0x785c('0xc'),'as':'Variable','attributes':['id',_0x785c('0x2')]}]},{'model':'FreshdeskField','as':'Descriptions','attributes':['id',_0x785c('0xd'),_0x785c('0xa'),_0x785c('0xe'),_0x785c('0xf'),_0x785c('0x10'),_0x785c('0xb')],'include':[{'model':_0x785c('0xc'),'as':'Variable','attributes':['id',_0x785c('0x2')]}]},{'model':_0x785c('0x9'),'as':_0x785c('0x11'),'attributes':['id','type',_0x785c('0xa'),_0x785c('0x12'),_0x785c('0x13'),_0x785c('0x14'),_0x785c('0xb')],'include':[{'model':'Variable','as':_0x785c('0xc'),'attributes':['id',_0x785c('0x2')]}]}]}]},'log':_0x785c('0x15')});};};