02c69adb17dea051b0014aee6b761af424a92fe2
[motion2.git] / server / services / ami / rpc / integrations / zendesk.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 _0x5eb0=['../../client','GetZendeskAccount','name','username','remoteUri','type','ZendeskConfiguration','Configurations','ZendeskField','content','variableName','Variable','Descriptions','key','keyType','keyContent','Fields','idField','customField'];(function(_0x1eb05b,_0x257306){var _0x2706fa=function(_0x44014e){while(--_0x44014e){_0x1eb05b['push'](_0x1eb05b['shift']());}};_0x2706fa(++_0x257306);}(_0x5eb0,0x156));var _0x05eb=function(_0x40569c,_0x194cf8){_0x40569c=_0x40569c-0x0;var _0x4b6f42=_0x5eb0[_0x40569c];return _0x4b6f42;};'use strict';var client=require(_0x05eb('0x0'));exports['getZendeskAccounts']=function(){return function(_0x3e4897){return client['Request'](_0x05eb('0x1'),{'options':{'raw':![],'attributes':['id',_0x05eb('0x2'),_0x05eb('0x3'),'password','token',_0x05eb('0x4'),'authType','serverUrl',_0x05eb('0x5')],'include':[{'model':_0x05eb('0x6'),'as':_0x05eb('0x7'),'attributes':['id',_0x05eb('0x2')],'include':[{'model':'Tag','attributes':['id',_0x05eb('0x2')]},{'model':_0x05eb('0x8'),'as':'Subjects','attributes':['id',_0x05eb('0x5'),_0x05eb('0x9'),_0x05eb('0xa')],'include':[{'model':_0x05eb('0xb'),'as':'Variable','attributes':['id',_0x05eb('0x2')]}]},{'model':_0x05eb('0x8'),'as':_0x05eb('0xc'),'attributes':['id',_0x05eb('0x5'),_0x05eb('0x9'),_0x05eb('0xd'),_0x05eb('0xe'),_0x05eb('0xf'),_0x05eb('0xa')],'include':[{'model':_0x05eb('0xb'),'as':_0x05eb('0xb'),'attributes':['id',_0x05eb('0x2')]}]},{'model':_0x05eb('0x8'),'as':_0x05eb('0x10'),'attributes':['id',_0x05eb('0x5'),_0x05eb('0x9'),_0x05eb('0x11'),'nameField',_0x05eb('0x12'),_0x05eb('0xa')],'include':[{'model':_0x05eb('0xb'),'as':'Variable','attributes':['id',_0x05eb('0x2')]}]}]}]},'log':_0x05eb('0x1')});};};