17 lines
592 B
JavaScript
17 lines
592 B
JavaScript
const express = require('express');
|
|
const statisticsRouter = express.Router();
|
|
|
|
const statisticsController = require('../controllers/statisticsController');
|
|
|
|
// ! /statistics
|
|
// * GET - All Time, Watch Time
|
|
statisticsRouter.get('/watch-time', statisticsController.getAllTimeWatchTime);
|
|
|
|
// * GET - Yearly Watch Time
|
|
statisticsRouter.get('/watch-time/year/:year', statisticsController.getYearlyWatchTime);
|
|
|
|
// * GET - Yearly Watch Count Grouped By Month
|
|
statisticsRouter.get('/watch-count/year/:year', statisticsController.getYearlyWatchCountGroupByMonth);
|
|
|
|
module.exports = statisticsRouter;
|