04c5ac87f61102e3fee0db84451450e8a35feb30
[motion.git] / server / api / voice_voicemail / index.js
1 'use strict';
2
3 var express = require('express');
4 var controller = require('./voice_voicemail.controller');
5 var auth = require('../../auth/auth.service');
6
7 var router = express.Router();
8
9 router.get('/', auth.isAuthenticated(), controller.index);
10 router.get('/:uniqueid', auth.isAuthenticated(), controller.show);
11 router.get('/:uniqueid/messages', auth.isAuthenticated(), controller.getMessages);
12 router.get('/messages/:id/download', auth.isAuthenticated(), controller.downloadMessage);
13 router.post('/', auth.isAuthenticated(), controller.create);
14 router.post('/validate', auth.isAuthenticated(), controller.mailboxValidation);
15 router.put('/:uniqueid', auth.isAuthenticated(), controller.update);
16 router.patch('/:id', auth.isAuthenticated(), controller.update);
17 router.delete('/', auth.isAuthenticated(), controller.bulkDestroy);
18 router.delete('/:uniqueid', auth.isAuthenticated(), controller.destroy);
19 router.delete('/messages/:id/delete', auth.isAuthenticated(), controller.destroyMessage);
20
21 module.exports = router;