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