feat(backend): '/auth/hello' endpoint toegevoegd

This commit is contained in:
Gerald Schmittinger 2025-04-19 11:27:51 +02:00
parent c2f3a6169a
commit 2b3f6b5e7a
6 changed files with 40 additions and 7 deletions

View file

@ -1,5 +1,5 @@
import express from 'express';
import { getFrontendAuthConfig } from '../controllers/auth.js';
import { getFrontendAuthConfig, postHelloHandler } from '../controllers/auth.js';
import { authenticatedOnly, studentsOnly, teachersOnly } from '../middleware/auth/auth.js';
const router = express.Router();
@ -23,4 +23,6 @@ router.get('/testTeachersOnly', teachersOnly, (_req, res) => {
res.json({ message: 'If you see this, you should be a teacher!' });
});
router.post('/hello', authenticatedOnly, postHelloHandler);
export default router;