feat:add candidate apis

This commit is contained in:
ARJUN S THAMPI
2026-03-13 16:26:06 +05:30
parent 7955465be4
commit 9faa512c0b
5 changed files with 267 additions and 0 deletions

View File

@@ -0,0 +1,25 @@
import express from "express";
import {
createCandidate,
getCandidates,
getCandidate,
getCandidatesByCareer,
updateCandidate,
deleteCandidate,
} from "../controllers/candidate.controller.js";
import jwtAuthMiddleware from "../middleware/auth.js";
const router = express.Router();
/* PUBLIC */
router.get("/getAll", getCandidates);
router.get("/:id", getCandidate);
router.get("/career/:careerId", getCandidatesByCareer);
router.post("/", createCandidate);
router.patch("/:id", updateCandidate);
router.delete("/:id", jwtAuthMiddleware, deleteCandidate);
export default router;