1a6c63003eeaff29173415a24ad7e562af7faf20
[motion2.git] / server / api / openchannelAccount / index.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 _0x1cb9=['exports','multer','path','connect-timeout','express','Router','../../components/auth/service','../../components/interaction/service','./openchannelAccount.controller','get','isAuthenticated','index','/describe','describe','/:id','show','/:id/dispositions','getDispositions','/:id/canned_answers','getAnswers','getApplications','/:id/interactions','getInteractions','getAgents','post','addAnswer','/:id/notify','notify','/:id/applications','addAgents','put','update','destroy','removeDispositions','delete','removeAnswers','/:id/users'];(function(_0x2f1a40,_0x1bb5a3){var _0x2c8dac=function(_0x446acf){while(--_0x446acf){_0x2f1a40['push'](_0x2f1a40['shift']());}};_0x2c8dac(++_0x1bb5a3);}(_0x1cb9,0x14e));var _0x91cb=function(_0xdcfa4a,_0x1a8e2c){_0xdcfa4a=_0xdcfa4a-0x0;var _0x335061=_0x1cb9[_0xdcfa4a];return _0x335061;};'use strict';var multer=require(_0x91cb('0x0'));var util=require('util');var path=require(_0x91cb('0x1'));var timeout=require(_0x91cb('0x2'));var express=require(_0x91cb('0x3'));var router=express[_0x91cb('0x4')]();var fs_extra=require('fs-extra');var auth=require(_0x91cb('0x5'));var interaction=require(_0x91cb('0x6'));var config=require('../../config/environment');var controller=require(_0x91cb('0x7'));router[_0x91cb('0x8')]('/',auth[_0x91cb('0x9')](),controller[_0x91cb('0xa')]);router[_0x91cb('0x8')](_0x91cb('0xb'),auth['isAuthenticated'](),controller[_0x91cb('0xc')]);router['get'](_0x91cb('0xd'),auth['isAuthenticated'](),controller[_0x91cb('0xe')]);router[_0x91cb('0x8')](_0x91cb('0xf'),auth[_0x91cb('0x9')](),controller[_0x91cb('0x10')]);router[_0x91cb('0x8')](_0x91cb('0x11'),auth[_0x91cb('0x9')](),controller[_0x91cb('0x12')]);router[_0x91cb('0x8')]('/:id/applications',auth[_0x91cb('0x9')](),controller[_0x91cb('0x13')]);router['get'](_0x91cb('0x14'),auth[_0x91cb('0x9')](),controller[_0x91cb('0x15')]);router[_0x91cb('0x8')]('/:id/users',auth['isAuthenticated'](),controller[_0x91cb('0x16')]);router[_0x91cb('0x17')]('/',auth['isAuthenticated'](),controller['create']);router[_0x91cb('0x17')](_0x91cb('0xf'),auth[_0x91cb('0x9')](),controller['addDisposition']);router[_0x91cb('0x17')](_0x91cb('0x11'),auth['isAuthenticated'](),controller[_0x91cb('0x18')]);router[_0x91cb('0x17')](_0x91cb('0x19'),controller[_0x91cb('0x1a')]);router['post'](_0x91cb('0x1b'),auth[_0x91cb('0x9')](),controller['addApplications']);router[_0x91cb('0x17')]('/:id/users',auth['isAuthenticated'](),controller[_0x91cb('0x1c')]);router[_0x91cb('0x17')]('/:id/send',auth['isAuthenticated'](),controller['send']);router[_0x91cb('0x1d')](_0x91cb('0xd'),auth[_0x91cb('0x9')](),controller[_0x91cb('0x1e')]);router['delete'](_0x91cb('0xd'),auth[_0x91cb('0x9')](),controller[_0x91cb('0x1f')]);router['delete'](_0x91cb('0xf'),auth[_0x91cb('0x9')](),controller[_0x91cb('0x20')]);router[_0x91cb('0x21')](_0x91cb('0x11'),auth[_0x91cb('0x9')](),controller[_0x91cb('0x22')]);router[_0x91cb('0x21')](_0x91cb('0x23'),auth['isAuthenticated'](),controller['removeAgents']);module[_0x91cb('0x24')]=router;