Files
habitica/website/server/controllers/api-v3/cron.js
2019-10-08 16:57:10 +02:00

23 lines
421 B
JavaScript

import { authWithHeaders } from '../../middlewares/auth';
import cron from '../../middlewares/cron';
const api = {};
/**
* @api {post} /api/v3/cron Runs cron
* @apiName Cron
* @apiGroup Cron
*
* @apiSuccess {Object} data An empty Object
*/
api.cron = {
method: 'POST',
url: '/cron',
middlewares: [authWithHeaders(), cron],
async handler (req, res) {
res.respond(200, {});
},
};
export default api;