Built motion from commit 449495f6.|2.6.27
[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 _0x1b65=['removeTags','multer','util','path','connect-timeout','Router','fs-extra','../../components/auth/service','../../components/interaction/service','../../config/environment','./whatsappInteraction.controller','get','index','/describe','isAuthenticated','/:id','show','getMessages','/:id/download','/:id/messages','addMessage','/:id/tags','tracked','whatsapp','whatsappinteraction:addtags','addTags','whatsappinteraction:update','delete','whatsappinteraction:destroy'];(function(_0x43f99d,_0xacc489){var _0x52a2e5=function(_0x54cb3f){while(--_0x54cb3f){_0x43f99d['push'](_0x43f99d['shift']());}};_0x52a2e5(++_0xacc489);}(_0x1b65,0x1b4));var _0x51b6=function(_0x31dbd9,_0x452f48){_0x31dbd9=_0x31dbd9-0x0;var _0x23a849=_0x1b65[_0x31dbd9];return _0x23a849;};'use strict';var multer=require(_0x51b6('0x0'));var util=require(_0x51b6('0x1'));var path=require(_0x51b6('0x2'));var timeout=require(_0x51b6('0x3'));var express=require('express');var router=express[_0x51b6('0x4')]();var fs_extra=require(_0x51b6('0x5'));var auth=require(_0x51b6('0x6'));var interaction=require(_0x51b6('0x7'));var config=require(_0x51b6('0x8'));var controller=require(_0x51b6('0x9'));router[_0x51b6('0xa')]('/',auth['isAuthenticated'](),controller[_0x51b6('0xb')]);router[_0x51b6('0xa')](_0x51b6('0xc'),auth[_0x51b6('0xd')](),controller['describe']);router[_0x51b6('0xa')](_0x51b6('0xe'),auth['isAuthenticated'](),controller[_0x51b6('0xf')]);router['get']('/:id/messages',auth[_0x51b6('0xd')](),controller[_0x51b6('0x10')]);router[_0x51b6('0xa')](_0x51b6('0x11'),auth[_0x51b6('0xd')](),controller['download']);router['post']('/',auth[_0x51b6('0xd')](),controller['create']);router['post'](_0x51b6('0x12'),auth['isAuthenticated'](),controller[_0x51b6('0x13')]);router['post'](_0x51b6('0x14'),auth[_0x51b6('0xd')](),interaction[_0x51b6('0x15')](_0x51b6('0x16'),_0x51b6('0x17')),controller[_0x51b6('0x18')]);router['put'](_0x51b6('0xe'),auth[_0x51b6('0xd')](),interaction[_0x51b6('0x15')]('whatsapp',_0x51b6('0x19')),controller['update']);router[_0x51b6('0x1a')](_0x51b6('0xe'),auth[_0x51b6('0xd')](),interaction[_0x51b6('0x15')](_0x51b6('0x16'),_0x51b6('0x1b')),controller['destroy']);router[_0x51b6('0x1a')]('/:id/tags',auth[_0x51b6('0xd')](),controller[_0x51b6('0x1c')]);module['exports']=router;