9868058592653167626e075d79296500c2378d1d
[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 _0xdbb1=['/:id','show','/:id/messages','getMessages','/:id/download','download','post','addMessage','tracked','whatsapp','whatsappinteraction:addtags','addTags','whatsappinteraction:update','update','whatsappinteraction:destroy','destroy','delete','/:id/tags','multer','express','../../components/auth/service','../../config/environment','./whatsappInteraction.controller','index','get','/describe','isAuthenticated'];(function(_0x51e347,_0x1b565a){var _0x49ab46=function(_0x5962cf){while(--_0x5962cf){_0x51e347['push'](_0x51e347['shift']());}};_0x49ab46(++_0x1b565a);}(_0xdbb1,0x105));var _0x1dbb=function(_0x4d07cc,_0x587613){_0x4d07cc=_0x4d07cc-0x0;var _0x42de3b=_0xdbb1[_0x4d07cc];return _0x42de3b;};'use strict';var multer=require(_0x1dbb('0x0'));var util=require('util');var path=require('path');var timeout=require('connect-timeout');var express=require(_0x1dbb('0x1'));var router=express['Router']();var fs_extra=require('fs-extra');var auth=require(_0x1dbb('0x2'));var interaction=require('../../components/interaction/service');var config=require(_0x1dbb('0x3'));var controller=require(_0x1dbb('0x4'));router['get']('/',auth['isAuthenticated'](),controller[_0x1dbb('0x5')]);router[_0x1dbb('0x6')](_0x1dbb('0x7'),auth[_0x1dbb('0x8')](),controller['describe']);router[_0x1dbb('0x6')](_0x1dbb('0x9'),auth['isAuthenticated'](),controller[_0x1dbb('0xa')]);router[_0x1dbb('0x6')](_0x1dbb('0xb'),auth[_0x1dbb('0x8')](),controller[_0x1dbb('0xc')]);router[_0x1dbb('0x6')](_0x1dbb('0xd'),auth[_0x1dbb('0x8')](),controller[_0x1dbb('0xe')]);router[_0x1dbb('0xf')]('/',auth[_0x1dbb('0x8')](),controller['create']);router[_0x1dbb('0xf')](_0x1dbb('0xb'),auth[_0x1dbb('0x8')](),controller[_0x1dbb('0x10')]);router['post']('/:id/tags',auth[_0x1dbb('0x8')](),interaction[_0x1dbb('0x11')](_0x1dbb('0x12'),_0x1dbb('0x13')),controller[_0x1dbb('0x14')]);router['put'](_0x1dbb('0x9'),auth[_0x1dbb('0x8')](),interaction[_0x1dbb('0x11')]('whatsapp',_0x1dbb('0x15')),controller[_0x1dbb('0x16')]);router['delete'](_0x1dbb('0x9'),auth[_0x1dbb('0x8')](),interaction[_0x1dbb('0x11')](_0x1dbb('0x12'),_0x1dbb('0x17')),controller[_0x1dbb('0x18')]);router[_0x1dbb('0x19')](_0x1dbb('0x1a'),auth['isAuthenticated'](),controller['removeTags']);module['exports']=router;