d190fc286fce6fd4fd933f36ef448302da37484c
[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 _0xb20b=['getMessages','/:id/download','post','create','/:id/tags','tracked','addTags','put','update','whatsapp','destroy','exports','multer','path','connect-timeout','express','Router','../../components/auth/service','../../components/interaction/service','../../config/environment','./whatsappInteraction.controller','index','get','/describe','isAuthenticated','show','/:id/messages'];(function(_0x2965ba,_0x1df010){var _0x2829a3=function(_0x32d923){while(--_0x32d923){_0x2965ba['push'](_0x2965ba['shift']());}};_0x2829a3(++_0x1df010);}(_0xb20b,0x93));var _0xbb20=function(_0x34951f,_0x4b9a30){_0x34951f=_0x34951f-0x0;var _0x4ff01c=_0xb20b[_0x34951f];return _0x4ff01c;};'use strict';var multer=require(_0xbb20('0x0'));var util=require('util');var path=require(_0xbb20('0x1'));var timeout=require(_0xbb20('0x2'));var express=require(_0xbb20('0x3'));var router=express[_0xbb20('0x4')]();var auth=require(_0xbb20('0x5'));var interaction=require(_0xbb20('0x6'));var config=require(_0xbb20('0x7'));var controller=require(_0xbb20('0x8'));router['get']('/',auth['isAuthenticated'](),controller[_0xbb20('0x9')]);router[_0xbb20('0xa')](_0xbb20('0xb'),auth['isAuthenticated'](),controller['describe']);router['get']('/:id',auth[_0xbb20('0xc')](),controller[_0xbb20('0xd')]);router['get'](_0xbb20('0xe'),auth[_0xbb20('0xc')](),controller[_0xbb20('0xf')]);router[_0xbb20('0xa')](_0xbb20('0x10'),auth[_0xbb20('0xc')](),controller['download']);router[_0xbb20('0x11')]('/',auth['isAuthenticated'](),controller[_0xbb20('0x12')]);router[_0xbb20('0x11')](_0xbb20('0xe'),auth[_0xbb20('0xc')](),controller['addMessage']);router[_0xbb20('0x11')](_0xbb20('0x13'),auth[_0xbb20('0xc')](),interaction[_0xbb20('0x14')]('whatsapp','whatsappinteraction:addtags'),controller[_0xbb20('0x15')]);router[_0xbb20('0x16')]('/:id',auth[_0xbb20('0xc')](),interaction[_0xbb20('0x14')]('whatsapp','whatsappinteraction:update'),controller[_0xbb20('0x17')]);router['delete']('/:id',auth[_0xbb20('0xc')](),interaction[_0xbb20('0x14')](_0xbb20('0x18'),'whatsappinteraction:destroy'),controller[_0xbb20('0x19')]);router['delete']('/:id/tags',auth[_0xbb20('0xc')](),controller['removeTags']);module[_0xbb20('0x1a')]=router;