Built motion from commit 53172ac8.|2.6.30
[motion2.git] / server / api / whatsappAccount / 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 _0x613e=['util','path','Router','../../components/interaction/service','../../config/environment','get','isAuthenticated','index','/describe','describe','/:id','show','/:id/dispositions','/:id/users','getAgents','/:id/applications','getApplications','create','post','addDisposition','addAnswer','addAgents','addApplications','/:id/notify','notify','send','put','update','delete','destroy','/:id/canned_answers','removeAnswers','exports','multer'];(function(_0x591e16,_0x5aefc1){var _0x543b35=function(_0x81e3be){while(--_0x81e3be){_0x591e16['push'](_0x591e16['shift']());}};_0x543b35(++_0x5aefc1);}(_0x613e,0x131));var _0xe613=function(_0x32ff94,_0x4c03f4){_0x32ff94=_0x32ff94-0x0;var _0x439bc8=_0x613e[_0x32ff94];return _0x439bc8;};'use strict';var multer=require(_0xe613('0x0'));var util=require(_0xe613('0x1'));var path=require(_0xe613('0x2'));var timeout=require('connect-timeout');var express=require('express');var router=express[_0xe613('0x3')]();var fs_extra=require('fs-extra');var auth=require('../../components/auth/service');var interaction=require(_0xe613('0x4'));var config=require(_0xe613('0x5'));var controller=require('./whatsappAccount.controller');router[_0xe613('0x6')]('/',auth[_0xe613('0x7')](),controller[_0xe613('0x8')]);router[_0xe613('0x6')](_0xe613('0x9'),auth['isAuthenticated'](),controller[_0xe613('0xa')]);router[_0xe613('0x6')](_0xe613('0xb'),auth[_0xe613('0x7')](),controller[_0xe613('0xc')]);router[_0xe613('0x6')](_0xe613('0xd'),auth[_0xe613('0x7')](),controller['getDispositions']);router[_0xe613('0x6')]('/:id/canned_answers',auth[_0xe613('0x7')](),controller['getAnswers']);router[_0xe613('0x6')](_0xe613('0xe'),auth[_0xe613('0x7')](),controller[_0xe613('0xf')]);router[_0xe613('0x6')](_0xe613('0x10'),auth[_0xe613('0x7')](),controller[_0xe613('0x11')]);router['post']('/',auth['isAuthenticated'](),controller[_0xe613('0x12')]);router[_0xe613('0x13')](_0xe613('0xd'),auth[_0xe613('0x7')](),controller[_0xe613('0x14')]);router['post']('/:id/canned_answers',auth[_0xe613('0x7')](),controller[_0xe613('0x15')]);router[_0xe613('0x13')]('/:id/users',auth[_0xe613('0x7')](),controller[_0xe613('0x16')]);router[_0xe613('0x13')](_0xe613('0x10'),auth[_0xe613('0x7')](),controller[_0xe613('0x17')]);router[_0xe613('0x13')](_0xe613('0x18'),controller[_0xe613('0x19')]);router['post']('/:id/send',auth[_0xe613('0x7')](),controller[_0xe613('0x1a')]);router[_0xe613('0x1b')]('/:id',auth['isAuthenticated'](),controller[_0xe613('0x1c')]);router[_0xe613('0x1d')](_0xe613('0xb'),auth[_0xe613('0x7')](),controller[_0xe613('0x1e')]);router['delete']('/:id/dispositions',auth[_0xe613('0x7')](),controller['removeDispositions']);router['delete'](_0xe613('0x1f'),auth[_0xe613('0x7')](),controller[_0xe613('0x20')]);router[_0xe613('0x1d')](_0xe613('0xe'),auth['isAuthenticated'](),controller['removeAgents']);module[_0xe613('0x21')]=router;