3f093280428cb8a84dcafd627cdfee86521f299f
[motion2.git] / server / api / whatsappInteraction / 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 _0x25fa=['update','delete','whatsappinteraction:destroy','removeTags','multer','path','connect-timeout','Router','fs-extra','../../components/auth/service','./whatsappInteraction.controller','isAuthenticated','index','get','/describe','describe','/:id','/:id/messages','getMessages','/:id/download','post','addMessage','/:id/tags','tracked','whatsapp','whatsappinteraction:addtags','addTags','put','whatsappinteraction:update'];(function(_0x56323a,_0x36b29c){var _0x2606af=function(_0x55e103){while(--_0x55e103){_0x56323a['push'](_0x56323a['shift']());}};_0x2606af(++_0x36b29c);}(_0x25fa,0x109));var _0xa25f=function(_0x254a99,_0x90ae06){_0x254a99=_0x254a99-0x0;var _0x52882f=_0x25fa[_0x254a99];return _0x52882f;};'use strict';var multer=require(_0xa25f('0x0'));var util=require('util');var path=require(_0xa25f('0x1'));var timeout=require(_0xa25f('0x2'));var express=require('express');var router=express[_0xa25f('0x3')]();var fs_extra=require(_0xa25f('0x4'));var auth=require(_0xa25f('0x5'));var interaction=require('../../components/interaction/service');var config=require('../../config/environment');var controller=require(_0xa25f('0x6'));router['get']('/',auth[_0xa25f('0x7')](),controller[_0xa25f('0x8')]);router[_0xa25f('0x9')](_0xa25f('0xa'),auth[_0xa25f('0x7')](),controller[_0xa25f('0xb')]);router[_0xa25f('0x9')](_0xa25f('0xc'),auth[_0xa25f('0x7')](),controller['show']);router[_0xa25f('0x9')](_0xa25f('0xd'),auth['isAuthenticated'](),controller[_0xa25f('0xe')]);router[_0xa25f('0x9')](_0xa25f('0xf'),auth[_0xa25f('0x7')](),controller['download']);router[_0xa25f('0x10')]('/',auth[_0xa25f('0x7')](),controller['create']);router[_0xa25f('0x10')](_0xa25f('0xd'),auth['isAuthenticated'](),controller[_0xa25f('0x11')]);router[_0xa25f('0x10')](_0xa25f('0x12'),auth[_0xa25f('0x7')](),interaction[_0xa25f('0x13')](_0xa25f('0x14'),_0xa25f('0x15')),controller[_0xa25f('0x16')]);router[_0xa25f('0x17')](_0xa25f('0xc'),auth[_0xa25f('0x7')](),interaction[_0xa25f('0x13')]('whatsapp',_0xa25f('0x18')),controller[_0xa25f('0x19')]);router[_0xa25f('0x1a')](_0xa25f('0xc'),auth[_0xa25f('0x7')](),interaction[_0xa25f('0x13')]('whatsapp',_0xa25f('0x1b')),controller['destroy']);router[_0xa25f('0x1a')]('/:id/tags',auth['isAuthenticated'](),controller[_0xa25f('0x1c')]);module['exports']=router;