d21fd0af1e2bf20d3374ca0a2a5b0da187418e52
[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 _0xa846=['nameField','customField','getFreshdeskAccounts','Request','GetFreshdeskAccount','name','username','remoteUri','serverUrl','Configurations','Tag','Subjects','content','Variable','FreshdeskField','Descriptions','type','key','keyType','variableName','Fields','idField'];(function(_0x4fbb15,_0x21be0c){var _0x436338=function(_0x3b5a05){while(--_0x3b5a05){_0x4fbb15['push'](_0x4fbb15['shift']());}};_0x436338(++_0x21be0c);}(_0xa846,0x70));var _0x6a84=function(_0x4f0098,_0x3c8d4e){_0x4f0098=_0x4f0098-0x0;var _0x4dfe28=_0xa846[_0x4f0098];return _0x4dfe28;};'use strict';var client=require('../../client');exports[_0x6a84('0x0')]=function(){return function(_0xf5ca75){return client[_0x6a84('0x1')](_0x6a84('0x2'),{'options':{'raw':![],'attributes':['id',_0x6a84('0x3'),_0x6a84('0x4'),'apiKey',_0x6a84('0x5'),_0x6a84('0x6')],'include':[{'model':'FreshdeskConfiguration','as':_0x6a84('0x7'),'attributes':['id',_0x6a84('0x3')],'include':[{'model':_0x6a84('0x8'),'attributes':['id',_0x6a84('0x3')]},{'model':'FreshdeskField','as':_0x6a84('0x9'),'attributes':['id','type',_0x6a84('0xa'),'variableName'],'include':[{'model':_0x6a84('0xb'),'as':'Variable','attributes':['id',_0x6a84('0x3')]}]},{'model':_0x6a84('0xc'),'as':_0x6a84('0xd'),'attributes':['id',_0x6a84('0xe'),_0x6a84('0xa'),_0x6a84('0xf'),_0x6a84('0x10'),'keyContent',_0x6a84('0x11')],'include':[{'model':_0x6a84('0xb'),'as':'Variable','attributes':['id',_0x6a84('0x3')]}]},{'model':'FreshdeskField','as':_0x6a84('0x12'),'attributes':['id',_0x6a84('0xe'),_0x6a84('0xa'),_0x6a84('0x13'),_0x6a84('0x14'),_0x6a84('0x15'),'variableName'],'include':[{'model':'Variable','as':_0x6a84('0xb'),'attributes':['id',_0x6a84('0x3')]}]}]}]},'log':_0x6a84('0x2')});};};