2016-05-17 19:50:37 +00:00
|
|
|
import { Router } from 'express';
|
|
|
|
import * as UserController from '../controllers/user.controller';
|
2017-02-22 19:29:35 +00:00
|
|
|
|
2016-05-17 19:50:37 +00:00
|
|
|
const router = new Router();
|
|
|
|
|
2016-06-09 00:52:59 +00:00
|
|
|
router.route('/signup').post(UserController.createUser);
|
|
|
|
|
2016-09-02 18:51:30 +00:00
|
|
|
router.route('/signup/duplicate_check').get(UserController.duplicateUserCheck);
|
|
|
|
|
2016-08-05 01:43:13 +00:00
|
|
|
router.route('/preferences').put(UserController.updatePreferences);
|
|
|
|
|
2016-10-12 18:25:24 +00:00
|
|
|
router.route('/reset-password').post(UserController.resetPasswordInitiate);
|
|
|
|
|
2016-10-18 20:07:25 +00:00
|
|
|
router.route('/reset-password/:token').get(UserController.validateResetPasswordToken);
|
|
|
|
|
|
|
|
router.route('/reset-password/:token').post(UserController.updatePassword);
|
|
|
|
|
2017-03-16 22:25:12 +00:00
|
|
|
router.route('/account').put(UserController.updateSettings);
|
|
|
|
|
2017-06-26 16:48:28 +00:00
|
|
|
router.route('/verify/send').post(UserController.emailVerificationInitiate);
|
|
|
|
|
|
|
|
router.route('/verify').get(UserController.verifyEmail);
|
|
|
|
|
2016-05-17 19:50:37 +00:00
|
|
|
export default router;
|